Skip to content

Commit

Permalink
Enables Deno specific tests in Core
Browse files Browse the repository at this point in the history
Core features which are environment dependent will need to be implemented.
For testing this features, environment dependent tests need to be setup.

The `deno` tests can be run by `npm run test::deno` and they need to be located under `./packages/core/test/deno`.
The testkit pipeline is configured to run these tests only when configured for test `deno`.
  • Loading branch information
bigmontz committed Apr 4, 2023
1 parent 93c0a16 commit 72b8636
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 3 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
"build::notci": "lerna bootstrap",
"docs": "lerna run docs --stream --concurrency 1",
"test::unit": "lerna run test::unit --stream",
"test::deno": "lerna run test::deno --stream",
"test::integration": "lerna run test::integration --stream",
"test::browser": "lerna run test::browser --stream",
"test::stress": "lerna run test::stress --stream",
Expand Down
7 changes: 4 additions & 3 deletions packages/core/jest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,10 @@ export default {
// ],

// An array of regexp pattern strings that are matched against all test paths, matched tests are skipped
// testPathIgnorePatterns: [
// "/node_modules/"
// ],
testPathIgnorePatterns: [
"/node_modules/",
"/test/deno/"
],

// The regexp pattern or array of patterns that Jest uses to detect test files
// testRegex: [],
Expand Down
1 change: 1 addition & 0 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"test": "jest",
"test::watch": "jest --watch",
"test::unit": "npm run test",
"test::deno": "deno test --allow-none ./test/deno/",
"predocs": "npm run build && npm run build::es6",
"docs": "esdoc -c esdoc.json",
"prepare": "npm run build",
Expand Down
Empty file.
3 changes: 3 additions & 0 deletions testkit/unittests.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@

run_in_driver_repo(["npm", "run", "lint"])
run_in_driver_repo(["npm", "run", "test::unit", "--", ignore])

if is_deno():
run_in_driver_repo(["npm" "run", "test::deno"])

0 comments on commit 72b8636

Please sign in to comment.