|
1 | | -# Testing with playwright-browserstack in Test Runner |
| 1 | +Check out the sample repository provided below, which demonstrates how to run Playwright tests on BrowserStack using the Playwright test runner: |
2 | 2 |
|
3 | | -[Playwright](https://playwright.dev/) Integration with BrowserStack. |
| 3 | +https://github.com/browserstack/node-js-playwright-browserstack |
4 | 4 |
|
5 | | - |
6 | | - |
7 | | -## Setup |
8 | | - |
9 | | -* Clone the repo and run `cd playwright-test` |
10 | | -* Run `npm install` |
11 | | - |
12 | | -## Running your tests |
13 | | - |
14 | | -- To run a single test, run `npm test` |
15 | | - |
16 | | - ### Run sample test on privately hosted websites |
17 | | - |
18 | | - **Using Command-line Interface** |
19 | | - 1. You have to download the BrowserStack Local binary from the links below (depending on your environment): |
20 | | - * [OS X (10.7 and above)](https://www.browserstack.com/browserstack-local/BrowserStackLocal-darwin-x64.zip) |
21 | | - * [Linux 32-bit](https://www.browserstack.com/browserstack-local/BrowserStackLocal-linux-ia32.zip) |
22 | | - * [Linux 64-bit](https://www.browserstack.com/browserstack-local/BrowserStackLocal-linux-x64.zip) |
23 | | - * [Windows (XP and above)](https://www.browserstack.com/browserstack-local/BrowserStackLocal-win32.zip) |
24 | | - 2. Once you have downloaded and unzipped the file, you can initiate the binary by running the command: `./BrowserStackLocal --key YOUR_ACCESS_KEY` |
25 | | - 3. Once you see the terminal say "[SUCCESS]" You can now access your local server(s) in our remote browser”, your local testing connection is considered established. |
26 | | - 4. You can then run the sample Local test using `npm run test:local` |
27 | | - |
28 | | -Understand how many parallel sessions you need by using our [Parallel Test Calculator](https://www.browserstack.com/automate/parallel-calculator?ref=github) |
29 | | - |
30 | | - |
31 | | -## Notes |
32 | | -* You can view your test results on the [BrowserStack Automate dashboard](https://www.browserstack.com/automate) |
33 | | - |
34 | | -## Additional Resources |
35 | | -* [Documentation for writing Automate test scripts with BrowserStack](https://www.browserstack.com/docs/automate/playwright) |
| 5 | +This repository serves as a helpful reference for setting up and executing Playwright tests seamlessly on BrowserStack. |
0 commit comments