Gauge (software)

{{Short description|Cross-platform test automation tool}}

{{Use mdy dates|date=April 2017}}

{{Infobox software

| developer = ThoughtWorks

| latest release version = {{wikidata|property|edit|reference|P348}}

| latest release date = {{start date and age|{{wikidata|qualifier|P348|P577}}}}

| programming language = Go

| operating_system = Platform-independent

| genre = Test automation tool

| license = Apache License 2.0

| website = {{Official URL}}

}}

Gauge is a light weight cross-platform test automation tool. It uses markdown to author test cases and scenarios. Its modular architecture makes it flexible and scalable.

Markdown

Gauge specifications{{cite web|url=https://docs.getgauge.io/longstart.html#specifications-spec|title=Long Start – Gauge 0.8.3 documentation|publisher=|accessdate=April 28, 2017|archive-date=March 7, 2017|archive-url=https://web.archive.org/web/20170307045012/https://docs.getgauge.io/longstart.html#specifications-spec|url-status=dead}} are written in the business language. For example,

Find movies playing near me

=======================

The System Under Test in this example is a web application to find and book movie tickets

Search for movies

-----------------

  • Specify location as "Bangalore"
  • Search for movie "Star Wars"
  • Verify that "INOX" is playing "Star Wars" at "7:30 pm"

Book movie ticket

-----------------

  • Sign up with email address
  • Complete the verification
  • Select location as "Bangalore", the movie "Star Wars" and "3" seats
  • Confirm and pay
  • Verify the "e-ticket" has been sent to the registered email.

This Gauge specification describes a feature of the System Under Test. The scenarios{{cite web|url=https://docs.getgauge.io/longstart.html#scenarios|title=Long Start – Gauge 0.8.3 documentation|publisher=|accessdate=April 28, 2017|archive-date=March 7, 2017|archive-url=https://web.archive.org/web/20170307045012/https://docs.getgauge.io/longstart.html#scenarios|url-status=dead}} Search for movies and Book movie ticket represent a flow in this specification. Steps{{cite web|url=https://docs.getgauge.io/longstart.html#steps|title=Long Start – Gauge 0.8.3 documentation|publisher=|accessdate=April 28, 2017|archive-date=March 7, 2017|archive-url=https://web.archive.org/web/20170307045012/https://docs.getgauge.io/longstart.html#steps|url-status=dead}} are executable parts of a specification.

=Test Code=

Specifications in Markdown abstracts code behind the steps.

For example, the step Specify location as "Bangalore" implementation in Java would look like

// This Method can be written in any java class as long as it is in classpath.

public class StepImplementation {

@Step("Specify location as ")

public void helloWorld(String location) {

// Step implementation

}

}

Gauge has Support for writing test code in:

The Community contributed language runners are:

=Execution=

Gauge tests can be executed from the command line{{cite web|url=https://docs.getgauge.io/using.html#command-line-interface|title=Using Gauge – Gauge 0.8.3 documentation|publisher=|accessdate=April 28, 2017|archive-date=March 6, 2017|archive-url=https://web.archive.org/web/20170306211351/https://docs.getgauge.io/using.html#command-line-interface|url-status=dead}} or the supported IDEs.{{cite web|url=https://docs.getgauge.io/using.html#id7|title=Using Gauge – Gauge 0.8.3 documentation|publisher=|accessdate=April 28, 2017|archive-date=March 6, 2017|archive-url=https://web.archive.org/web/20170306211351/https://docs.getgauge.io/using.html#id7|url-status=dead}}

The default command gauge specs run the tests sequentially.

The command gauge -p specs will execute the tests in Parallel.

=Reports=

Gauge gives comprehensive test reports{{cite web|url=https://docs.getgauge.io/reports.html|title=Reports – Gauge 0.8.3 documentation|publisher=|accessdate=April 28, 2017|archive-date=March 6, 2017|archive-url=https://web.archive.org/web/20170306211230/https://docs.getgauge.io/reports.html|url-status=dead}} that provides the required details of a given run.

=IDE support=

Gauge's IDE support helps to write and maintain the test suite.

References

{{reflist|30em}}