Skip to content

Commit

Permalink
Enables jsx tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dhuebner committed Nov 9, 2023
1 parent f785425 commit 6e6fb9b
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 11 deletions.
1 change: 0 additions & 1 deletion packages/sprotty/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
"tinyqueue": "^2.0.3"
},
"devDependencies": {
"@types/chai": "^4.3.6",
"@types/file-saver": "^2.0.5",
"@types/jsdom": "^21.1.3",
"jsdom": "^22.1.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

/** @jsx svg */
import { svg } from '../../lib/jsx';
import 'reflect-metadata';

import { expect, describe, it } from 'vitest';
import { CssClassPostprocessor } from './css-class-postprocessor';
Expand Down
5 changes: 3 additions & 2 deletions packages/sprotty/src/base/views/thunk-view.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@

/** @jsx svg */
import { svg } from '../../lib/jsx';
import 'reflect-metadata';

import { expect, describe, it } from 'vitest';
import { expect, describe, beforeAll, it } from 'vitest';
import { init } from "snabbdom";
import { SModelElementImpl } from "../model/smodel";
import { ModelRenderer } from './viewer';
Expand All @@ -28,7 +29,7 @@ import toHTML from 'snabbdom-to-html';

describe('ThunkView', () => {

before(function () {
beforeAll(function () {
setup();
});

Expand Down
2 changes: 0 additions & 2 deletions packages/sprotty/src/lib/jsx.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
/** @jsx svg */
import { svg } from './jsx';

import 'mocha';
import { expect } from 'chai';
import { h } from 'snabbdom';

const svgNS = 'http://www.w3.org/2000/svg';
Expand Down
2 changes: 1 addition & 1 deletion vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export default defineConfig({
deps: {
interopDefault: true
},
include: ['**/*.spec.ts'],
include: ['**/*.spec.ts', '**/*.spec.tsx'],
globals: true,
}
});
5 changes: 0 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -862,11 +862,6 @@
resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.3.9.tgz#144d762491967db8c6dea38e03d2206c2623feec"
integrity sha512-69TtiDzu0bcmKQv3yg1Zx409/Kd7r0b5F1PfpYJfSHzLGtB53547V4u+9iqKYsTu/O2ai6KTb0TInNpvuQ3qmg==

"@types/chai@^4.3.6":
version "4.3.6"
resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.3.6.tgz#7b489e8baf393d5dd1266fb203ddd4ea941259e6"
integrity sha512-VOVRLM1mBxIRxydiViqPcKn6MIxZytrbMpd6RJLIWKxUNr3zux8no0Oc7kJx0WAPIitgZ0gkrDS+btlqQpubpw==

"@types/connect@*":
version "3.4.36"
resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.36.tgz#e511558c15a39cb29bd5357eebb57bd1459cd1ab"
Expand Down

0 comments on commit 6e6fb9b

Please sign in to comment.