This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Grab("org.grails:gorm-hibernate4-spring-boot:1.1.0.RELEASE") | |
@Grab("Microsoft:mssql-driver-jdbc4:4.0") | |
@GrabExclude('org.codehaus.groovy:groovy-all') | |
import grails.persistence.* | |
import grails.orm.bootstrap.* | |
import com.microsoft.sqlserver.jdbc.SQLServerDriver | |
import org.springframework.jdbc.datasource.DriverManagerDataSource |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Grab("org.grails:gorm-hibernate4-spring-boot:1.1.0.RELEASE") | |
@Grab("Microsoft:mssql-driver-jdbc4:4.0") | |
@GrabExclude('org.codehaus.groovy:groovy-all') | |
import grails.persistence.* | |
import grails.orm.bootstrap.* | |
import com.microsoft.sqlserver.jdbc.SQLServerDriver | |
import org.springframework.jdbc.datasource.DriverManagerDataSource |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Grapes ( | |
[@Grab("org.seleniumhq.selenium:selenium-java:2.40.0") | |
, @Grab("org.seleniumhq.selenium:selenium-support:2.40.0")]) | |
import org.openqa.selenium.WebDriver | |
import org.openqa.selenium.firefox.FirefoxDriver | |
import org.openqa.selenium.support.PageFactory | |
import org.openqa.selenium.support.FindBy | |
import org.openqa.selenium.By | |
import org.openqa.selenium.WebElement |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
groovy.lang.GroovyRuntimeException: Could not find matching constructor for: myplace.dsl.DmaDSL(myplace.steps.support.TestEnvironment) | |
at groovy.lang.MetaClassImpl.invokeConstructor(MetaClassImpl.java:1601) | |
at groovy.lang.MetaClassImpl.invokeConstructor(MetaClassImpl.java:1404) | |
at org.codehaus.groovy.runtime.callsite.MetaClassConstructorSite.callConstructor(MetaClassConstructorSite.java:46) | |
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:57) | |
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:182) | |
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:190) | |
at myplace.steps.support.DMAWorld.<init>(env.groovy:29) | |
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) | |
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
class DmaDSL { | |
private final WebDriver driver | |
private final TestEnvironment testEnvironment | |
... | |
DmaDSL(TestEnvironment tstEnv) { | |
testEnvironment = tstEnv | |
driver = testEnvironment.driver |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package myplace.steps.support | |
import cucumber.runtime.ScenarioImpl | |
import cucumber.api.groovy.Hooks | |
import org.openqa.selenium.OutputType | |
import org.openqa.selenium.TakesScreenshot | |
import org.openqa.selenium.WebDriver | |
import myplace.dsl.DmaDSL | |
this.metaClass.mixin(Hooks) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cucumber.support | |
import cucumber.api.groovy.Hooks | |
import cucumber.helpers.MyHelper | |
this.metaClass.mixin(Hooks) | |
class CucumberWithGroovyWorld { | |
@Delegate MyHelper myHelper | |
@Delegate TestEnvironment testEnvironment |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cucumber.steps | |
import cucumber.api.DataTable | |
import cucumber.support.CucumberWithGroovyWorld | |
import org.stag.qa.Calculator | |
import static cucumber.api.groovy.EN.* | |
import static cucumber.api.groovy.Hooks.Before | |
CucumberWithGroovyWorld world |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>com.groovy.example</groupId> | |
<artifactId>groovymeta-example</artifactId> | |
<version>1.0-SNAPSHOT</version> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Scenario Outline: This is an example of a scenario outline | |
Given this is a scenario outline | |
When we concatenate <string_1> with <string_2> | |
Then the combined string is <string_3> | |
Examples: | |
|string_1 | string_2 | string_3 | | |
| hello | world | helloworld | | |
| good | bye | goodbye | |
NewerOlder