Refactorization: Moved code out of macro TEST_CASE