feat(webpack): default tsconfig.json if not found

This commit is contained in:
Igor Randjelovic
2022-02-18 15:17:06 +01:00
parent 4fa51b6064
commit 48c51f6163
14 changed files with 934 additions and 44 deletions

View File

@ -1,5 +1,11 @@
import Config from 'webpack-chain';
import {
mockExistsSync,
restoreExistsSync,
setHasTSConfig,
} from '../../scripts/jest.utils';
import svelte from '../../src/configuration/svelte';
import { init } from '../../src';
@ -8,6 +14,15 @@ jest.mock('__jest__/svelte.config.js', () => {}, { virtual: true });
describe('svelte configuration', () => {
const platforms = ['ios', 'android'];
beforeAll(() => {
mockExistsSync();
setHasTSConfig(true);
});
afterAll(() => {
restoreExistsSync();
});
for (let platform of platforms) {
it(`for ${platform}`, () => {
init({