aboutsummaryrefslogtreecommitdiffstats
path: root/gentests.js
diff options
context:
space:
mode:
authorbrunobar79 <brunobar79@gmail.com>2018-07-03 07:36:26 +0800
committerbrunobar79 <brunobar79@gmail.com>2018-07-03 07:36:26 +0800
commitbbc0d6f48df9d09ab96c5ffd1087877c563eb6c5 (patch)
tree0c5ba506f67e7d006ed20fe9be866ca206c8392e /gentests.js
parent03ff8a7cfa043539a58863aa7496c33167e815b1 (diff)
downloadtangerine-wallet-browser-bbc0d6f48df9d09ab96c5ffd1087877c563eb6c5.tar
tangerine-wallet-browser-bbc0d6f48df9d09ab96c5ffd1087877c563eb6c5.tar.gz
tangerine-wallet-browser-bbc0d6f48df9d09ab96c5ffd1087877c563eb6c5.tar.bz2
tangerine-wallet-browser-bbc0d6f48df9d09ab96c5ffd1087877c563eb6c5.tar.lz
tangerine-wallet-browser-bbc0d6f48df9d09ab96c5ffd1087877c563eb6c5.tar.xz
tangerine-wallet-browser-bbc0d6f48df9d09ab96c5ffd1087877c563eb6c5.tar.zst
tangerine-wallet-browser-bbc0d6f48df9d09ab96c5ffd1087877c563eb6c5.zip
fix gentests.js
Diffstat (limited to 'gentests.js')
-rw-r--r--gentests.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/gentests.js b/gentests.js
index 5f1d716fd..9c591e98c 100644
--- a/gentests.js
+++ b/gentests.js
@@ -1,4 +1,5 @@
const fs = require('fs')
+const path = require('path')
const async = require('async')
const promisify = require('pify')
@@ -58,12 +59,12 @@ async function startContainer (fileRegEx, testGenerator) {
const testFilePath = sPath.replace('.', '-').replace('.', '.test.')
await promisify(fs.readFile)(
- __dirname + '/' + sFile,
+ path.join(__dirname, sFile),
'utf8',
async (err, result) => {
if (err) {
console.log('Error: ', err)
- } else {
+ } else {
console.log(`result`, result.length)
const returnObjectStrings = result
.match(/return\s(\{[\s\S]+?})\n}/g)