Skip to content

Commit

Permalink
[ci] format
Browse files Browse the repository at this point in the history
  • Loading branch information
Princesseuh authored and astrobot-houston committed Apr 12, 2024
1 parent 308b5d8 commit 174ce25
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
4 changes: 2 additions & 2 deletions packages/astro/src/core/config/tsconfig.ts
@@ -1,12 +1,12 @@
import { readFile } from 'node:fs/promises';
import { join } from 'node:path';
import { readFile } from "node:fs/promises"
import {
TSConfckParseError,
type TSConfckParseOptions,
type TSConfckParseResult,
find,
parse,
toJson
toJson,
} from 'tsconfck';
import type { CompilerOptions, TypeAcquisition } from 'typescript';

Expand Down
9 changes: 5 additions & 4 deletions packages/astro/test/units/config/config-tsconfig.test.js
@@ -1,10 +1,10 @@
import * as assert from 'node:assert/strict';
import { readFile } from 'node:fs/promises';
import * as path from 'node:path';
import { describe, it } from 'node:test';
import { fileURLToPath } from 'node:url';
import { loadTSConfig, updateTSConfigForFramework } from '../../../dist/core/config/index.js';
import { readFile } from 'node:fs/promises';
import { toJson } from 'tsconfck';
import { loadTSConfig, updateTSConfigForFramework } from '../../../dist/core/config/index.js';

const cwd = fileURLToPath(new URL('../../fixtures/tsconfig-handling/', import.meta.url));

Expand Down Expand Up @@ -42,8 +42,9 @@ describe('TSConfig handling', () => {

it('does not change baseUrl in raw config', async () => {
const loadedConfig = await loadTSConfig(path.join(cwd, 'baseUrl'));
const rawConfig = await readFile(path.join(cwd, 'baseUrl', 'tsconfig.json'), 'utf-8').then(toJson)
.then((content) => JSON.parse(content));
const rawConfig = await readFile(path.join(cwd, 'baseUrl', 'tsconfig.json'), 'utf-8')
.then(toJson)
.then((content) => JSON.parse(content));

assert.deepEqual(loadedConfig.rawConfig, rawConfig);
});
Expand Down

0 comments on commit 174ce25

Please sign in to comment.