While moving all tests to v3/ I found out that the StandaloneTestBase uses MetaClient.resetUnrecoverably() to clear the state of the standalpone CDAP after each test. So far, that was calling a v2 API that only deleted the default namespace. That is sufficient to make tests pass.
But this method should actually delete all namespaces. Currently, we have no API to do that.