Organize tests

This commit is contained in:
Tim Schaub
2021-04-27 15:41:14 -07:00
parent 278e355795
commit 490cfabe91
599 changed files with 12374 additions and 1603 deletions

View File

@@ -0,0 +1,29 @@
import {VERSION} from '../../../../../src/ol/util.js';
import {create} from '../../../../../src/ol/worker/version.js';
describe('ol/worker/version', function () {
let worker;
beforeEach(function () {
worker = create();
});
afterEach(function () {
if (worker) {
worker.terminate();
}
worker = null;
});
describe('messaging', function () {
it('responds with the version', function (done) {
worker.addEventListener('error', done);
worker.addEventListener('message', function (event) {
expect(event.data).to.equal('version: ' + VERSION);
done();
});
worker.postMessage('test message');
});
});
});