mirror of
https://github.com/movie-web/providers.git
synced 2025-09-13 18:13:25 +00:00
fix ts config for tests, so my IDE doesnt complain
This commit is contained in:
@@ -2,7 +2,7 @@ import { mockEmbeds, mockSources } from '@/__test__/providerTests';
|
||||
import { getProviders } from '@/providers/get';
|
||||
import { vi, describe, it, expect, afterEach } from 'vitest';
|
||||
|
||||
const mocks = await vi.hoisted(async () => (await import('@/__test__/providerTests')).makeProviderMocks());
|
||||
const mocks = await vi.hoisted(async () => (await import('../providerTests.ts')).makeProviderMocks());
|
||||
vi.mock('@/providers/all', () => mocks);
|
||||
|
||||
describe('getProviders()', () => {
|
||||
|
@@ -2,7 +2,7 @@ import { mockEmbeds, mockSources } from '@/__test__/providerTests';
|
||||
import { makeProviders } from '@/main/builder';
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest';
|
||||
|
||||
const mocks = await vi.hoisted(async () => (await import('@/__test__/providerTests')).makeProviderMocks());
|
||||
const mocks = await vi.hoisted(async () => (await import('../providerTests.ts')).makeProviderMocks());
|
||||
vi.mock('@/providers/all', () => mocks);
|
||||
|
||||
describe('ProviderControls.listSources()', () => {
|
||||
|
@@ -2,7 +2,7 @@ import { mockEmbeds, mockSources } from '@/__test__/providerTests';
|
||||
import { makeProviders } from '@/main/builder';
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest';
|
||||
|
||||
const mocks = await vi.hoisted(async () => (await import('@/__test__/providerTests')).makeProviderMocks());
|
||||
const mocks = await vi.hoisted(async () => (await import('../providerTests.ts')).makeProviderMocks());
|
||||
vi.mock('@/providers/all', () => mocks);
|
||||
|
||||
describe('ProviderControls.getMetadata()', () => {
|
||||
|
21
src/__test__/tsconfig.json
Normal file
21
src/__test__/tsconfig.json
Normal file
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"target": "ES2022",
|
||||
"lib": ["ES2022"],
|
||||
"module": "ES2022",
|
||||
"declaration": true,
|
||||
"outDir": "./lib",
|
||||
"strict": true,
|
||||
"moduleResolution": "NodeNext",
|
||||
"allowImportingTsExtensions": true,
|
||||
"noEmit": true,
|
||||
"experimentalDecorators": true,
|
||||
"isolatedModules": false,
|
||||
"skipLibCheck": true,
|
||||
"paths": {
|
||||
"@/*": ["../*"],
|
||||
"@entrypoint": ["../index.ts"]
|
||||
}
|
||||
},
|
||||
"include": ["./"]
|
||||
}
|
Reference in New Issue
Block a user