Skip to content

Commit

Permalink
Fixed tests
Browse files Browse the repository at this point in the history
  • Loading branch information
GermanBluefox committed Apr 10, 2024
1 parent f6597f3 commit a176671
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 8 deletions.
5 changes: 3 additions & 2 deletions packages/iobroker.vis-2/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ function buildRuntime() {
}

gulp.task('runtime-0-clean', done => {
deleteFoldersRecursive(`${__dirname}/www`);
deleteFoldersRecursive(`${__dirname}/../../www`);
deleteFoldersRecursive(`${__dirname}/runtime`, ['node_modules', 'package-lock.json']);
done();
});
Expand Down Expand Up @@ -198,15 +200,14 @@ gulp.task('runtime-6-copy-dep', gulp.series('runtime-4-build-dep', 'runtime-6-co
gulp.task('runtime-7-patch', done => {
patchFile(`${__dirname}/www/index.html`);
patchFile(`${__dirname}/runtime/build/index.html`);
copyFolder(`${__dirname}/www`, `${__dirname}/../../www`);
done();
});

gulp.task('runtime-7-patch-dep', gulp.series('runtime-6-copy-dep', 'runtime-7-patch'));

gulp.task('0-clean', done => {
deleteFoldersRecursive(`${__dirname}/src/build`);
deleteFoldersRecursive(`${__dirname}/www`);
deleteFoldersRecursive(`${__dirname}/../../www`);
done();
});

Expand Down
1 change: 0 additions & 1 deletion packages/iobroker.vis-2/io-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@
}
},
"compact": true,
"materialize": true,
"eraseOnUpload": true,
"welcomeScreen": [
{
Expand Down
2 changes: 1 addition & 1 deletion packages/iobroker.vis-2/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"@alcalzone/release-script": "^3.7.0",
"@alcalzone/release-script-plugin-iobroker": "^3.7.0",
"@alcalzone/release-script-plugin-license": "^3.7.0",
"@iobroker/vis-2-widgets-testing": "^1.0.1",
"@iobroker/vis-2-widgets-testing": "^1.0.2",
"@tsconfig/node18": "^18.2.4",
"@types/mocha": "^10.0.6",
"chai": "^4.4.1",
Expand Down
6 changes: 3 additions & 3 deletions packages/iobroker.vis-2/test/testAdapter.gui.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const helper = require('@iobroker/vis-2-widgets-testing');
const path = require('path')
const path = require('node:path')

let gPage;
let gBrowser;
Expand All @@ -14,7 +14,7 @@ describe('vis', () => {
additionalAdapters: ['web'],
visUploadedId: 'vis-2.0.info.uploaded',
mainGuiProject: 'vis-2',
rootDir: path.join(__dirname, '..') + '/'
rootDir: path.normalize(`${path.join(__dirname, '..')}/`).replace(/\\/g, '/'),
});
const { browser, page } = await helper.startBrowser(process.env.CI === 'true');
gBrowser = browser
Expand Down Expand Up @@ -71,4 +71,4 @@ describe('vis', () => {
await helper.stopIoBroker();
console.log('ioBroker stopped');
});
});
});
4 changes: 3 additions & 1 deletion packages/iobroker.vis-2/test/testPackageFiles.engine.js
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
require('@iobroker/legacy-testing/tests/testPackageFiles');
const path = require('node:path');
process.env.IOBROKER_ROOT_DIR = path.normalize(`${__dirname}/../`).replace(/\\/g, '/');
require('@iobroker/legacy-testing/tests/testPackageFiles');

0 comments on commit a176671

Please sign in to comment.