Make Vitest helpers global
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import { it, expect, describe } from 'vitest';
|
||||
import { createButton } from './button.js';
|
||||
|
||||
describe('createButton', () => {
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
import { it, expect } from 'vitest';
|
||||
|
||||
it('should properly assign to localStorage', () => {
|
||||
const key = 'secret';
|
||||
const message = "It's a secret to everybody.";
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { describe, expect, it, beforeEach, vi, afterEach } from 'vitest';
|
||||
import { screen } from '@testing-library/dom';
|
||||
import userEvent from '@testing-library/user-event';
|
||||
import { createSecretInput } from './secret-input.js';
|
||||
|
||||
@@ -3,5 +3,6 @@ import { defineConfig } from 'vitest/config';
|
||||
export default defineConfig({
|
||||
test: {
|
||||
environment: 'happy-dom',
|
||||
globals: true,
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user