Skip to content

Commit

Permalink
Make confetti test file
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonStnn committed Jun 18, 2024
1 parent ba56db9 commit 68d639b
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions tests/balloons/confetti.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import { Confetti } from '@/balloons';
import fetchMock from 'jest-fetch-mock';

fetchMock.enableMocks();

describe('Confetti Balloon', () => {
let balloon: Confetti;

beforeEach(() => {
balloon = new Confetti();

fetchMock.resetMocks();
});

test('name should be "confetti"', () => {
expect(balloon.name).toBe('confetti');
});

test('name should be the same as the class name', () => {
expect(balloon.name).toBe('confetti');
expect(balloon.name).toBe(Confetti.name.toLowerCase());
});
});

0 comments on commit 68d639b

Please sign in to comment.