Skip to content

Commit

Permalink
Version update 1.46
Browse files Browse the repository at this point in the history
Updated the config file
  • Loading branch information
jagota-s committed Aug 11, 2024
1 parent a1a44a1 commit 2ad61d8
Show file tree
Hide file tree
Showing 4 changed files with 68 additions and 39 deletions.
83 changes: 57 additions & 26 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
"license": "ISC",
"devDependencies": {
"@axe-core/playwright": "4.6.0",
"@playwright/test": "^1.42.1",
"@playwright/test": "^1.46.0",
"@types/node": "^22.2.0",
"allure-playwright": "^2.0.0-beta.20"
}
}
18 changes: 7 additions & 11 deletions playwright.config.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import type { PlaywrightTestConfig } from '@playwright/test';
import { devices } from '@playwright/test';
import { defineConfig, devices } from '@playwright/test';

/**
* Read environment variables from file.
Expand All @@ -10,7 +9,7 @@ import { devices } from '@playwright/test';
/**
* See https://playwright.dev/docs/test-configuration.
*/
const config: PlaywrightTestConfig = {
export default defineConfig({
testDir: './tests',
/* Maximum time one test can run for. */
timeout: 20 * 1000,
Expand All @@ -19,7 +18,7 @@ const config: PlaywrightTestConfig = {
* Maximum time expect() should wait for the condition to be met.
* For example in `await expect(locator).toHaveText();`
*/
timeout: 5000
timeout: 5000,
},

/* Run tests in files in parallel */
Expand All @@ -40,7 +39,7 @@ const config: PlaywrightTestConfig = {
use: {
viewport: null,
// extraHTTPHeaders: {
// "Authorozation" : "Basic"
// "Authorization" : "Basic"
// },
/* Maximum time each action such as `click()` can take. Defaults to 0 (no limit). */
actionTimeout: 0,
Expand All @@ -52,8 +51,8 @@ const config: PlaywrightTestConfig = {
video: 'retry-with-video',
launchOptions: {
headless: true,
args: ["--start-maximized"]
}
args: ["--start-maximized"],
},
// httpCredentials: {
// username: 'bill',
// password: 'pa55w0rd',
Expand All @@ -68,7 +67,6 @@ const config: PlaywrightTestConfig = {
...devices['Desktop Chrome'],
screenshot: 'on',
trace: 'on',

},
},

Expand Down Expand Up @@ -108,7 +106,6 @@ const config: PlaywrightTestConfig = {
// },
// },
// {
// {
// name: 'Google Chrome',
// use: {
// channel: 'chrome',
Expand All @@ -124,6 +121,5 @@ const config: PlaywrightTestConfig = {
// command: 'npm run start',
// port: 3000,
// },
};
});

export default config;
3 changes: 2 additions & 1 deletion tests/networkMocking.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ test.describe('Network mocking examples', () => {
})
await loginPage.goTo();
await loginPage.validLogin(testData.username, testData.password);
await page.waitForResponse("https://rahulshettyacademy.com/api/ecom/product/get-all-products");
// await page.waitForResponse("https://rahulshettyacademy.com/api/ecom/product/get-all-products");
await page.close();
})

});

0 comments on commit 2ad61d8

Please sign in to comment.