Skip to content

Instantly share code, notes, and snippets.

@ojacques
Last active April 18, 2018 17:49
Show Gist options
  • Save ojacques/a8635872b00a635e80047584d2f9eb04 to your computer and use it in GitHub Desktop.
Save ojacques/a8635872b00a635e80047584d2f9eb04 to your computer and use it in GitHub Desktop.
DevOps Dojo Test Case
package io.github.zutherb.appstash.shop.ui.page.test
import geb.Page
import geb.spock.GebReportingSpec
import org.openqa.selenium.remote.DesiredCapabilities
import org.openqa.selenium.remote.RemoteWebDriver
import io.github.zutherb.appstash.common.util.Config
class DiscountSpec extends GebReportingSpec {
def "Check discount"() {
when:
to HomePage
assert discountHeader.text() == "Save!"
assert discountPercent.text() == Config.getProperty("GLOBAL_DISCOUNT")
assert discountLabel.text() == "You save"
and:
homeLink.click()
then:
at HomePage
}
}
@arunasure18
Copy link

add 25% discount

@t6856ga
Copy link

t6856ga commented Apr 18, 2018

Dojo class - test case example.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment