raniejade
03/23/2019, 1:54 AMmemoized
on your tests? https://github.com/spekframework/spek/pull/660 came up to eagerly evaluate memoized
during the execution phase instead of evaluating on access. Options: 👌, 🚫 and 🙃 if you didn’t know that memoized
is lazy.gildor
03/23/2019, 1:59 AMNikky
03/23/2019, 11:45 AMraniejade
03/24/2019, 3:33 AMraniejade
03/24/2019, 3:36 AMval foo by memoized { Foo() }
val bar by memoized { Bar() }
it("do something") {
assertEquals(foo.something(), bar.something())
}
is equivalent to (in terms of execution):
val foo = Foo()
val bar = Bar()
assertEquals(foo.something(), bar.something())