Commit 49b674b6 authored by ι™ˆεΈ…'s avatar ι™ˆεΈ…

Fix #logo does not exist for bugs

parent 2cc3e846
...@@ -10,9 +10,9 @@ describe('Homepage', () => { ...@@ -10,9 +10,9 @@ describe('Homepage', () => {
const browser = await puppeteer.launch({ args: ['--no-sandbox'] }); const browser = await puppeteer.launch({ args: ['--no-sandbox'] });
const page = await browser.newPage(); const page = await browser.newPage();
await page.goto(BASE_URL, { waitUntil: 'networkidle2' }); await page.goto(BASE_URL, { waitUntil: 'networkidle2' });
await page.waitForSelector('#logo h1'); const text = await page.evaluate(() => document.getElementsByTagName('h1')[0].innerText);
const text = await page.evaluate(() => document.body.innerHTML); expect(text).toContain('Ant Design Pro');
expect(text).toContain('<h1>Ant Design Pro</h1>');
await page.close(); await page.close();
browser.close(); browser.close();
}); });
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment