or even compose better functionality instead of in...
# spek
s
or even compose better functionality instead of inherit.. It seems hard with the way that it's all run in a block.
r
in spek 1.x there was include which let you compose tests
I think it did not make it into 2.x so far (I would use it was well)
s
I can't even find any documentation on that. searching
spek include
doesn't work very well as you can imagine.
t
mm, but you can compose tests using extension on
Suite
(if I am getting you right):
Copy code
fun Suite.mySuite() {
    context("zzz") {
        beforeEach {  }
        it("zzz") { }
    }
}
s
Yes, but I can’t put that in a separate class. It has to go along with the rest of the beforeEach, afterEach, etc.
t
what is preventing putting it in a separate class?
you can pass main suite memoized values as a param 🤔
s
hm. could you provide an example? How would the
beforeEachTest
be executed?