Skip to content

Commit

Permalink
slight testing of vitests
Browse files Browse the repository at this point in the history
  • Loading branch information
Lunga-Ntando-Ndlovu committed Jun 6, 2024
1 parent d6c085d commit cb2fd33
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/client/src/testing/Degrees.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { render } from '@testing-library/svelte';
import Degree from '../lib/components/admin/+Degrees.svelte';
import {expect,test} from 'vitest';
import { degrees } from '../routes/degrees';


degrees.forEach((degree) => {
test(`displays the degree: ${degree.program}`, () => {
const { getByText } = render(Degree, { degrees });
expect(getByText(degree.program)).toBeVisible();
});
});

0 comments on commit cb2fd33

Please sign in to comment.