Skip to content

Commit

Permalink
chore: add test
Browse files Browse the repository at this point in the history
  • Loading branch information
fireairforce committed Nov 23, 2023
1 parent 71c2c75 commit 909109e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions tests/integration/app-document/modern.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ export default applyBaseConfig({
},
html: {
favicon: './static/a.icon',
title: 'test-title',
},
plugins: [routerPlugin(), tmpTest()],
});
8 changes: 8 additions & 0 deletions tests/integration/app-document/tests/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,14 @@ describe('test dev and build', () => {
),
).toBe(true);
});

test('should has title in Head', async () => {
const htmlWithDoc = fs.readFileSync(
path.join(appDir, 'dist', 'html/sub/index.html'),
'utf-8',
);
expect(htmlWithDoc.includes('<title>test-title</title>')).toBe(true);
});
});

describe('test dev', () => {
Expand Down

0 comments on commit 909109e

Please sign in to comment.