项目作者: sridharbandi

项目描述 :
Selenium Groovy Junit Template, Compatible with Maven or Gradle
高级语言: Groovy
项目地址: git://github.com/sridharbandi/Selenium-Groovy-Junit-Template.git


Selenium Groovy Junit Template with Gradle or Maven as build tools to getting started with

To automate Selenium Webdriver binaries management in runtime am using webdrivermanager, an excellent library by Boni García

How to use?

Create the Page Objects of your Web application under pageobjects package and call those Page Objects in your jUnit tests under tests package (Sample Page Objects, testcase included in this template)

How to run?

Issue the below commands in project root directory

Gradle
  1. ./gradlew test

By default it runs in Chrome browser, you can specify which browser to use as well

  1. ./gradlew test -Dbrowser=firefox

If you’re on Windows replace ./gradlew with gradlew.bat

Currently supported browsers are

  • chrome
  • firefox
  • edge
  • ie
  • opera
Maven
  1. mvn test

Or

  1. mvn test -Dbrowser=firefox

Feel free to modify it to your own needs :)