[PATCH v4 10/14] selftests: harness: Add teardown callback to test metadata