Skip to content

Commit

Permalink
test(css): ✅ fix @barba/css tests
Browse files Browse the repository at this point in the history
  • Loading branch information
xavierfoucrier committed Mar 15, 2023
1 parent ae6f5f7 commit ff58813
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/css/__tests__/css.hooks.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,17 +50,17 @@ it('do leave hooks', async () => {
});

it('do enter hooks on first load', async () => {
// Remove from history to simulate first page load.
barba.history.remove();

await barba.hooks.do('beforeEnter', data, t);
await barba.hooks.do('afterEnter', data, t);

expect(css.start).not.toHaveBeenCalled();
expect(css.end).not.toHaveBeenCalled();
expect(css.start).toHaveBeenCalledWith(next, 'enter');
expect(css.end).toHaveBeenCalledWith(next, 'enter');
});

it('do enter hooks', async () => {
// Remove from history to simulate first page load.
barba.history.remove();

await barba.hooks.do('beforeEnter', data, t);
await barba.hooks.do('afterEnter', data, t);

Expand Down

0 comments on commit ff58813

Please sign in to comment.