Skip to content

Commit

Permalink
ci: setup vitest (#229)
Browse files Browse the repository at this point in the history
Co-authored-by: Marluan Espiritusanto <marluanespiritusanto@gmail.com>
  • Loading branch information
JeffreyArt1 and marluanespiritusanto authored Jun 18, 2024
1 parent 4cdb4d5 commit 4e4a95f
Show file tree
Hide file tree
Showing 6 changed files with 413 additions and 105 deletions.
2 changes: 1 addition & 1 deletion tests/app.test.ts → __tests__/app.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ describe('Basic Test Suite', () => {
it('should always pass', () => {
expect(true).toBe(true);
});
});
});
7 changes: 7 additions & 0 deletions __tests__/page.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { render, screen } from '@testing-library/react';
import { expect, test } from 'vitest';

test('Page', () => {
render(<h1 role="heading">Test</h1>);
expect(screen.getByRole('heading').textContent).toBe('Test');
});
11 changes: 6 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,8 @@
"@ory/integrations": "^1.2.1",
"@sentry/nextjs": "^7.80.0",
"@thgh/next-gtm": "^0.1.5",
"@types/bunyan": "^1.8.11",
"@types/react-gtm-module": "^2.0.3",
"aws-amplify": "^5.3.12",
"bunyan": "^1.8.15",
"check-password-strength": "^2.0.10",
"eslint": "^8.53.0",
"eslint-config-next": "^13.5.6",
"hibp": "^13.0.0",
"negotiator": "^0.6.3",
"next": "^13.5.6",
Expand All @@ -71,22 +66,28 @@
"devDependencies": {
"@commitlint/cli": "^18.4.0",
"@commitlint/config-conventional": "^18.4.0",
"@testing-library/react": "^15.0.7",
"@types/cookie": "^0.5.4",
"@types/negotiator": "^0.6.3",
"@types/node": "^20.12.12",
"@types/react": "^18.2.37",
"@types/react-dom": "^18.2.15",
"@types/react-google-recaptcha": "^2.1.9",
"@types/react-gtm-module": "^2.0.3",
"@typescript-eslint/eslint-plugin": "^6.10.0",
"@typescript-eslint/parser": "^6.10.0",
"@vitejs/plugin-react": "^4.2.1",
"aws-crt": "^1.19.0",
"encoding": "^0.1.13",
"eslint": "^8.53.0",
"eslint-config-next": "^13.5.6",
"eslint-config-prettier": "^9.1.0",
"eslint-import-resolver-typescript": "^3.6.1",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-prettier": "^5.1.3",
"husky": "^9.0.11",
"install-peers": "^1.0.4",
"jsdom": "^24.0.0",
"lint-staged": "^15.2.2",
"prettier": "^3.0.3",
"vitest": "^1.6.0"
Expand Down
Loading

0 comments on commit 4e4a95f

Please sign in to comment.