Added Accurest class for DSL
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
package io.codearte.accurest
|
||||
|
||||
import groovy.transform.EqualsAndHashCode
|
||||
import groovy.transform.ToString
|
||||
import groovy.transform.TypeChecked
|
||||
import io.codearte.accurest.dsl.GroovyDsl
|
||||
|
||||
/**
|
||||
* A better name for GroovyDsl
|
||||
*
|
||||
* @author Marcin Grzejszczak
|
||||
*/
|
||||
@TypeChecked
|
||||
@EqualsAndHashCode
|
||||
@ToString(includeFields = true, includePackage = false, includeNames = true, includeSuper = true)
|
||||
class Accurest extends GroovyDsl {
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
package io.codearte.accurest.builder
|
||||
|
||||
import io.codearte.accurest.Accurest
|
||||
import io.codearte.accurest.dsl.GroovyDsl
|
||||
import io.codearte.accurest.dsl.WireMockStubVerifier
|
||||
import spock.lang.Issue
|
||||
@@ -13,7 +14,7 @@ import java.util.regex.Pattern
|
||||
class MockMvcMethodBodyBuilderSpec extends Specification implements WireMockStubVerifier {
|
||||
|
||||
@Shared
|
||||
GroovyDsl dslWithOptionalsInString = GroovyDsl.make {
|
||||
GroovyDsl dslWithOptionalsInString = Accurest.make {
|
||||
priority 1
|
||||
request {
|
||||
method 'POST'
|
||||
|
||||
@@ -4,8 +4,9 @@ Contract DSL in Accurest is written in Groovy, but don't be alarmed if you didn'
|
||||
a tiny subset of it (namely literals, method calls and closures). What's more, Accurest's DSL is designed to be programmer-readable without any knowledge of the DSL itself -
|
||||
it's statically typed.
|
||||
|
||||
Let's look at full example of a contract definition.
|
||||
WARNING: Since {messaging_version} you can use the `io.codearte.accurest.Accurest` class in your DSL files.
|
||||
|
||||
Let's look at full example of a contract definition.
|
||||
|
||||
[source,groovy,indent=0]
|
||||
----
|
||||
|
||||
Reference in New Issue
Block a user