Skip to content

Commit

Permalink
Addressing malfunctioning code snippet. (#7789)
Browse files Browse the repository at this point in the history
  • Loading branch information
ExSidius authored and SimenB committed Feb 3, 2019
1 parent c6c60f5 commit 74ae342
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
4 changes: 2 additions & 2 deletions docs/Puppeteer.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ describe('Google', () => {
await page.goto('https://google.com');
});

it('should display "google" text on page', async () => {
await expect(page).toMatch('google');
it('should be titled "Google"', async () => {
await expect(page.title()).resolves.toMatch('Google');
});
});
```
Expand Down
3 changes: 1 addition & 2 deletions website/versioned_docs/version-22.x/Puppeteer.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,7 @@ describe(
}, timeout);

it('should load without error', async () => {
const text = await page.evaluate(() => document.body.textContent);
expect(text).toContain('google');
await expect(page.title()).resolves.toMatch('Google');
});
},
timeout,
Expand Down
4 changes: 2 additions & 2 deletions website/versioned_docs/version-23.x/Puppeteer.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ describe('Google', () => {
await page.goto('https://google.com');
});

it('should display "google" text on page', async () => {
await expect(page).toMatch('google');
it('should be titled "Google"', async () => {
await expect(page.title()).resolves.toMatch('Google');
});
});
```
Expand Down
4 changes: 2 additions & 2 deletions website/versioned_docs/version-24.0/Puppeteer.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ describe('Google', () => {
await page.goto('https://google.com');
});

it('should display "google" text on page', async () => {
await expect(page).toMatch('google');
it('should be titled "Google"', async () => {
await expect(page.title()).resolves.toMatch('Google');
});
});
```
Expand Down

0 comments on commit 74ae342

Please sign in to comment.