Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
env
 
 
 
 
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Deprecation notice

Do not use this sample. It's a reference on why page objects will burn your house. Gauge recommends not using page objects. Refer https://github.com/getgauge-examples/gauge-active-admin-example-maven and our blog

Gauge example in Java

Build Status

This is an example project for doing web automation testing with Gauge. This project tests some of the functionalities of the active admin demo app. This app is hosted as a Java WAR (with embedded Jetty).

Running this example

The tests are run on Chrome by default.

Prerequisites

This example requires the following softwares to run.

  • Java 1.7 or above
    • Note that Gauge works with Java 1.6 and above. But this particular example uses Java 1.7
  • Gauge
  • Gauge Java plugin
    • can be installed using gauge install java
  • Chrome

Setting up the System Under Test (SUT)

java -jar activeadmin-demo.war

Run specs

If you already have Gradle installed, you can execute specs as gradle specs. Otherwise, you can use the gradle wrapper and run specs as below:

On Linux / Mac

./gradlew gauge

On Windows

gradlew.bat gauge

This runs Gauge specs with Gradle.

This uses Chrome as default browser for specs execution. Make sure Chrome is installed in your machine and chromedriver is in PATH.

If you want to use Firefox/IE as browser, pass the corresponding argument to set browser environment as follows:

./gradlew gauge -Penv=firefox
or
./gradlew gauge -Penv=ie

Note:

  • Gauge can also be used with other build tools like maven and ant.
  • You can use Gauge even without a build script!

Topics covered in the example

Copyright

Copyright 2016, ThoughtWorks Inc.

About

A sample project illustrating Gauge features using webdriver

Resources

License

Releases

No releases published

Packages

No packages published
You can’t perform that action at this time.