Skip to content

imranwijaya/selenium-typescript-example

Repository files navigation

Selenium WebDriver Typescript using Page Object Models

This is an e2e testing example for this website using Selenium.

Getting Started

First, clone the repository & install the dependencies:

#clone github repository
git clone https://github.com/imranwijaya/selenium-typescript-example.git

#after successful clone
npm install

Run test with following command:

npm run test #run tests using browser specified in tests file
#or
npm run test:chrome #run tests using chrome headless browser
#or
npm run test:firefox #run tests using firefox headless browser

Folder Structure

.
├── ...
|── config/index.ts             # Test config (baseUrl, username, password, etc)
├── lib/
│     ├── browser.ts            # Builds WebDriver object for tests
|── pages/                      # Page Object Models
|── reports/                    # Test Report for the tests executed
|── tests/                      # Test Suites and Test Cases

Learn More

To learn more about Selenium, take a look at the following resources:

Releases

No releases published

Packages

No packages published