Skip to content
This repository was archived by the owner on Dec 12, 2025. It is now read-only.
This repository was archived by the owner on Dec 12, 2025. It is now read-only.

Clearly mark the test() method that it crosses the test boundaries #1

@mvysny

Description

@mvysny

There is no clear distinction between the code that creates tests (calls the test() method), and
the testing code itself (blocks inside of test() method). However, there is a ton of difference:
those two code bases run at completely different time. Furthermore Kotlin allows to share variables
freely between those two code bases, which may create a really dangerous code which fails in mysterious ways.

That's magic which must be removed. The test() method must yell a big warning sign that the programmer is crossing code boundaries. I'm thinking about renaming the test() method to something else, but I'm not really satisfied with any of the candidates:

  • post() - not really a test
  • postTest() - too long
  • marking test() deprecated - stupid :-)

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions