0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-02-17 22:44:24 -05:00

[ci] format

This commit is contained in:
Matt Kane 2025-01-09 16:10:58 +00:00 committed by astrobot-houston
parent 3c2292f2f0
commit df0c5665c1
3 changed files with 9 additions and 11 deletions

View file

@ -92,7 +92,7 @@ export default async function dev(inlineConfig: AstroInlineConfig): Promise<DevS
logger.error('content', err.message); logger.error('content', err.message);
} }
if(!store) { if (!store) {
logger.error('content', 'Failed to create data store'); logger.error('content', 'Failed to create data store');
} }

View file

@ -49,7 +49,7 @@ export type SyncOptions = {
cleanup?: boolean; cleanup?: boolean;
}; };
manifest: ManifestData; manifest: ManifestData;
command: "build" | "dev" | "sync"; command: 'build' | 'dev' | 'sync';
}; };
export default async function sync( export default async function sync(

View file

@ -1,8 +1,8 @@
import assert from 'node:assert/strict'; import assert from 'node:assert/strict';
import { promises as fs, existsSync } from 'node:fs';
import { after, afterEach, before, describe, it } from 'node:test'; import { after, afterEach, before, describe, it } from 'node:test';
import * as cheerio from 'cheerio'; import * as cheerio from 'cheerio';
import { loadFixture } from './test-utils.js'; import { loadFixture } from './test-utils.js';
import { existsSync, promises as fs } from 'node:fs';
describe('--mode', () => { describe('--mode', () => {
/** @type {import('./test-utils.js').Fixture} */ /** @type {import('./test-utils.js').Fixture} */
@ -51,7 +51,7 @@ describe('--mode', () => {
it('writes data store file in the correct location', async () => { it('writes data store file in the correct location', async () => {
assert.ok(existsSync(prodDataStoreFile)); assert.ok(existsSync(prodDataStoreFile));
}) });
}); });
describe('build --mode testing --devOutput', () => { describe('build --mode testing --devOutput', () => {
@ -68,12 +68,12 @@ describe('--mode', () => {
assert.equal($('#env-prod').text(), 'false'); assert.equal($('#env-prod').text(), 'false');
assert.equal($('#env-title').text(), ''); assert.equal($('#env-title').text(), '');
assert.equal($('#env-astro-title').text(), 'unset'); assert.equal($('#env-astro-title').text(), 'unset');
assert.ok assert.ok;
}); });
it('writes data store file in the correct location', async () => { it('writes data store file in the correct location', async () => {
assert.ok(existsSync(prodDataStoreFile)); assert.ok(existsSync(prodDataStoreFile));
}) });
}); });
describe('build --mode staging', () => { describe('build --mode staging', () => {
@ -94,8 +94,7 @@ describe('--mode', () => {
it('writes data store file in the correct location', async () => { it('writes data store file in the correct location', async () => {
assert.ok(existsSync(prodDataStoreFile)); assert.ok(existsSync(prodDataStoreFile));
}) });
}); });
describe('dev', () => { describe('dev', () => {
@ -123,7 +122,7 @@ describe('--mode', () => {
it('writes data store file in the correct location', async () => { it('writes data store file in the correct location', async () => {
assert.ok(existsSync(devDataStoreFile)); assert.ok(existsSync(devDataStoreFile));
}) });
}); });
describe('dev --mode develop', () => { describe('dev --mode develop', () => {
@ -151,7 +150,6 @@ describe('--mode', () => {
it('writes data store file in the correct location', async () => { it('writes data store file in the correct location', async () => {
assert.ok(existsSync(devDataStoreFile)); assert.ok(existsSync(devDataStoreFile));
}) });
}); });
}); });