Skip to content

Commit

Permalink
Add a stub test to test-app, add test script, unify testing in github…
Browse files Browse the repository at this point in the history
… action using `yarn workspaces run test`
  • Loading branch information
grantbacon-jaspersoft committed May 31, 2024
1 parent 624cd98 commit 633d1e2
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 10 deletions.
12 changes: 3 additions & 9 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,11 @@ jobs:
with:
node-version: ${{ matrix.node-version }}

- name: Build
- name: Build All
run: |
yarn install
yarn workspaces run build
- name: input-controls Test
- name: Test All
run: |
yarn test
working-directory: packages/input-controls

- name: test-app Test
run: |
yarn test
working-directory: packages/test-app
yarn workspaces run test
3 changes: 2 additions & 1 deletion packages/test-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"start": "esbuild ./src/entrypoint.tsx --outfile=public/bundle.js --bundle --watch --minify --sourcemap --servedir=public",
"build": "node esbuild.js",
"build-prod": "NODE_ENV=production node esbuild.js",
"clean": "rm -rf dist"
"clean": "rm -rf dist",
"test": "jest"
},
"devDependencies": {
"@types/react": "^18.3.3",
Expand Down
6 changes: 6 additions & 0 deletions packages/test-app/tests/stub.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
describe('stub tests, since none exist', () => {

it('should run tests', () => {
expect(1).toBe(1);
});
});

0 comments on commit 633d1e2

Please sign in to comment.