I forgot to say:
I have already tried this:
===
trait GebScriptingWindowTrait {
def withScriptingWindow(name, c) {
final cl = { title.startsWith(name) }
cl.delegate = c.delegate
final x = {
assert title.startsWith(name)
withWindow(cl, c)
}
x.delegate = c.delegate
returnsNull x
}
}
===
Which gets close, but no cigar:
===
assert title.startsWith(name)
| |
false TCE: Address Check
Assertion failed:
assert title.startsWith(name)
| |
false TCE: Address Check
at tce.GebScriptingWindowTrait$Trait$Helper.withScriptingWindow_closure2(GebScriptingWindowTrait.groovy:15)
at tce.GebScriptingWindowTrait$Trait$Helper.withScriptingWindow_closure2(GebScriptingWindowTrait.groovy)
at tce.GebHelperTrait$Trait$Helper.returnsNull(GebHelperTrait.groovy:6)
at tce.GebScriptingWindowTrait$Trait$Helper.withScriptingWindow(GebScriptingWindowTrait.groovy:19)
at tce.TCEExplosionSpec.explosion: flow: Address Check/Caller Supplied(TCEExplosionSpec.groovy:39)
===
Cheers,
BOB
>--
>You received this message because you are subscribed to the Google Groups "Geb User Mailing List" group.
>To unsubscribe from this group and stop receiving emails from it, send an email to
geb-user+u...@googlegroups.com.
>To post to this group, send email to
geb-...@googlegroups.com.
>To view this discussion on the web visit
https://groups.google.com/d/msgid/geb-user/50A09734-38D7-400E-BB06-AAF6ED17BF86%40transentia.com.au.
>For more options, visit
https://groups.google.com/d/optout.