https://github.com/browserstack/protractor-browserstack
Selenium examples for Protractor and BrowserStack Automate
https://github.com/browserstack/protractor-browserstack
Last synced: 11 months ago
JSON representation
Selenium examples for Protractor and BrowserStack Automate
- Host: GitHub
- URL: https://github.com/browserstack/protractor-browserstack
- Owner: browserstack
- Created: 2015-10-07T14:04:29.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2024-11-20T15:59:57.000Z (over 1 year ago)
- Last Synced: 2025-04-19T07:24:31.415Z (11 months ago)
- Language: JavaScript
- Homepage: https://www.browserstack.com
- Size: 245 KB
- Stars: 43
- Watchers: 14
- Forks: 45
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
- Codeowners: CODEOWNERS
Awesome Lists containing this project
README
# protractor-browserstack [deprecated]
[Protractor](https://github.com/angular/protractor/) Integration with BrowserStack.


---
**Protractor is no longer supported by the Angular team. If you're looking for alternatives, here are popular frameworks with migration guides:**
- **Selenium based**
- [Nightwatch](https://nightwatchjs.org/guide/migrating-to-nightwatch/from-protractor.html)
- [WebdriverIO](https://webdriver.io/docs/protractor-migration/)
- **Other Frameworks**
- [Cypress](https://docs.cypress.io/guides/migrating-to-cypress/protractor)
- [Playwright](https://playwright.dev/docs/protractor)
- [TestCafe](https://testcafe.io/documentation/403554/recipes/migration/migrate-tests-from-protractor-to-testcafe)
---
## Setup
* Clone the repo
* Install dependencies `npm install`
* Update `*.conf.js` files inside the `conf/` directory with your [BrowserStack Username and Access Key](https://www.browserstack.com/accounts/settings)
## Running your tests
* To run a single test, run `npm run single`
* To run local tests, run `npm run local`
* To run parallel tests, run `npm run parallel`
Understand how many parallel sessions you need by using our [Parallel Test Calculator](https://www.browserstack.com/automate/parallel-calculator?ref=github)
## Notes
* You can view your test results on the [BrowserStack automate dashboard](https://www.browserstack.com/automate)
* To test on a different set of browsers, check out our [platform configurator](https://www.browserstack.com/automate/node#setting-os-and-browser)
* You can export the environment variables for the Username and Access Key of your BrowserStack account
```
export BROWSERSTACK_USERNAME= &&
export BROWSERSTACK_ACCESS_KEY=
```
* Set browserstackUser and browserstackKey in config to automatically mark your test results, "completed" and "failed", on browserstack dashboard. [Sample config](conf/single.conf.js)
## Additional Resources
* [Documentation for writing automate test scripts in Node](https://www.browserstack.com/automate/node)
* [Customizing your tests on BrowserStack](https://www.browserstack.com/automate/capabilities)
* [Browsers & mobile devices for selenium testing on BrowserStack](https://www.browserstack.com/list-of-browsers-and-platforms?product=automate)
* [Using REST API to access information about your tests via the command-line interface](https://www.browserstack.com/automate/rest-api)