Skip to content

Commit 6470945

Browse files
committed
Changed Playwright-test script to use DuckDuckGo website
1 parent 1a0373a commit 6470945

File tree

9 files changed

+28
-28
lines changed

9 files changed

+28
-28
lines changed

playwright-test/tests/test_10.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Percy');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Percy - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Percy at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_2.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Playwright');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Playwright - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Playwright at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_3.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Puppeteer');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Puppeteer - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Puppeteer at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_4.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Cypress');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Cypress - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Cypress at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_5.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Local');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Local - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Local at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_6.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Selenium');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Selenium - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Selenium at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_7.spec.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
9-
await element.type('BrowserStack Speedlab');
9+
await element.type('BrowserStack SpeedLab');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Speedlab - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack SpeedLab at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_8.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Live');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Live - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Live at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

playwright-test/tests/test_9.spec.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ const { expect } = require('@playwright/test');
33
test.describe('feature foo', () => {
44
test('my test', async ({ page }) => {
55
// Assertions use the expect API.
6-
await page.goto('https://www.google.com/ncr');
7-
const element = await page.$('[aria-label="Search"]');
6+
await page.goto('https://www.duckduckgo.com');
7+
const element = await page.$('[name="q"]');
88
await element.click();
99
await element.type('BrowserStack Appium');
1010
await element.press('Enter');
1111
const title = await page.title('');
1212
console.log(title);
13-
expect(title).toEqual( 'BrowserStack Appium - Google Search', 'Expected page title is incorrect!');
13+
expect(title).toEqual( 'BrowserStack Appium at DuckDuckGo', 'Expected page title is incorrect!');
1414
});
1515
});

0 commit comments

Comments
 (0)