Skip to content
This repository was archived by the owner on Jan 30, 2025. It is now read-only.

Commit 4daf0a3

Browse files
committed
test(build-integration.test.ts): add
1 parent 96a1f94 commit 4daf0a3

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

test/build-integration.test.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import { exec } from 'child_process';
2+
import { promisify } from 'util';
3+
import path from 'path';
4+
5+
const execPromise = promisify(exec);
6+
7+
test('Should be build successfully and logs contain expected output', async () => {
8+
const { stdout } = await execPromise('npm run build', {
9+
cwd: path.join(__dirname, '../e2e/site'),
10+
});
11+
12+
console.log('stdout:', stdout);
13+
expect(stdout).toContain('Compiled successfully');
14+
expect(stdout).toContain('(Static) prerendered as static content');
15+
}, 20000);

0 commit comments

Comments
 (0)