Can't get the it syntax working

5 views
Skip to first unread message

Torbjørn

unread,
Oct 1, 2008, 5:52:24 AM10/1/08
to Easyb Users
I've got some problems with the it syntax in easyb.

Created a sipmle test like this:

it "should do something", {
println "something"
}

but all I got was this:

There was an error running your easyb story or specification
groovy.lang.MissingMethodException: No signature of method:
ItTestStory.it() is applicable for argument types: (java.lang.String,
ItTestStory$_run_closure1) values: {"should do something", ItTestStory
$_run_closure1@1ce3fc5}
at
org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:
54)
at
org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnCurrentN(ScriptBytecodeAdapter.java:
88)
at ItTestStory.run(ItTestStory.story:3)
at groovy.lang.GroovyShell.evaluate(GroovyShell.java:473)
at groovy.lang.GroovyShell.evaluate(GroovyShell.java:508)
at org.disco.easyb.domain.Story.execute(Story.java:26)
at org.disco.easyb.BehaviorRunner.runBehavior(BehaviorRunner.java:75)
at org.disco.easyb.BehaviorRunner.main(BehaviorRunner.java:56)

Any clues anyone?

Andrew Glover

unread,
Oct 1, 2008, 7:04:08 PM10/1/08
to easyb...@googlegroups.com
Sounds like the file you are running ends in .story, which easyb is interpreting as a story rather than a traditional "it" spec. If that's the case, try putting a .specification at the end of the file.
--
Sincerely,

Andrew Glover
703.577.0830 (cell)

Torbjørn

unread,
Oct 3, 2008, 1:59:01 AM10/3/08
to Easyb Users
Thanx!

It was the ending that was the problem.

<torbjørn/>
Reply all
Reply to author
Forward
0 new messages