https://kotlinlang.org logo
#announcements
Title
# announcements
m

mg6maciej

06/08/2017, 8:37 PM
@fmd Interesting. When would you separate test into blocks instead of simply creating two separate tests?
f

fmd

06/09/2017, 7:36 AM
mg6maciej: usually when I test lifecycle of components (i.e. creation -> destruction -> creation) if some form of persistent state is involved.
To express the separation of instances, I scope them into separate blocks. Also it keeps the local variable names clean and reusable without introducing
var
.
2 Views