Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

Commit

Permalink
update tests dependencies and stabilize tests
Browse files Browse the repository at this point in the history
  • Loading branch information
amiramw committed Dec 10, 2017
1 parent 02f0560 commit 753c82a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
10 changes: 5 additions & 5 deletions src/test/javascript/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@
"test": "mocha --timeout 20000"
},
"devDependencies": {
"chai": "4.1.1",
"mocha": "3.5.0",
"chai": "4.1.2",
"mocha": "4.0.1",
"promise": "8.0.1",
"sleep": "5.1.1",
"promise-timeout": "1.1.1",
"request": "2.81.0",
"request-promise": "4.2.1",
"ws": "3.1.0"
"request": "2.83.0",
"request-promise": "4.2.2",
"ws": "3.3.2"
},
"dependencies": {
"assert": "1.4.1"
Expand Down
2 changes: 1 addition & 1 deletion src/test/javascript/test/SyncNoWebsocket.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ describe('Sync Integration Test - no websocket', function () {
});
let form = req.form();
form.append('file', fs.createReadStream(zipFilePath));
}).then(function () {
}).delay(10).then(function () {
// putting file that already exists should fail
return new Promise(function (resolve) {
let req = request.put(pathPrefix + modulePath + '/java/test.java', COMMON_OPTIONS, function (err, res) {
Expand Down
12 changes: 6 additions & 6 deletions src/test/javascript/test/util/Util.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ const fs = require('fs');

module.exports = {

deleteFolderRecursive: function (path) {
var that = this;
deleteFolderRecursive: function (path) {
let that = this;
if (fs.existsSync(path)) {
fs.readdirSync(path).forEach(function(file,index){
var curPath = path + "/" + file;
fs.readdirSync(path).forEach(function (file, index) {
let curPath = path + "/" + file;
if (fs.lstatSync(curPath).isDirectory()) { // recurse
that.deleteFolderRecursive(curPath);
that.deleteFolderRecursive(curPath);
} else { // delete file
fs.unlinkSync(curPath);
}
Expand All @@ -17,4 +17,4 @@ module.exports = {
}
}

}
};

0 comments on commit 753c82a

Please sign in to comment.