-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(e2e): 录制完生成json,执行用例时再动态转成jest脚本,方便后期维护,增加功能修复bug之类的不需要重新录制脚本
re #80
- Loading branch information
fanniehuang
committed
Jan 22, 2021
1 parent
418b62c
commit 92c1c7d
Showing
12 changed files
with
326 additions
and
141 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
93 changes: 0 additions & 93 deletions
93
packages/wxa-cli/src/tester/wxa-e2eTest/e2eRecord2jsTpl.ejs
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
const fs = require('fs'); | ||
const ejs = require('ejs'); | ||
const path = require('path'); | ||
|
||
const e2eRecord2js = (data) => { | ||
return new Promise((resolve, reject) => { | ||
ejs.renderFile(path.join(__dirname + '/e2eTestCaseTpl.ejs'), data, (err, str) => { | ||
if (err) { | ||
return reject(err); | ||
} | ||
resolve(str); | ||
}); | ||
}); | ||
}; | ||
|
||
module.exports = e2eRecord2js; |
Oops, something went wrong.