Skip to content

Commit

Permalink
Mark all tests as used (rh-hideout#5531)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrgriffin authored Oct 25, 2024
1 parent 7413d10 commit 09c424b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions include/test/battle.h
Original file line number Diff line number Diff line change
Expand Up @@ -748,7 +748,7 @@ extern struct BattleTestRunnerState *const gBattleTestRunnerState;
#define BATTLE_TEST_ARGS_SINGLE(_name, _type, ...) \
struct CAT(Result, __LINE__) { RECURSIVELY(R_FOR_EACH(APPEND_SEMICOLON, __VA_ARGS__)) }; \
static void CAT(Test, __LINE__)(struct CAT(Result, __LINE__) *, const u32, struct BattlePokemon *, struct BattlePokemon *); \
__attribute__((section(".tests"))) static const struct Test CAT(sTest, __LINE__) = \
__attribute__((section(".tests"), used)) static const struct Test CAT(sTest, __LINE__) = \
{ \
.name = _name, \
.filename = __FILE__, \
Expand All @@ -766,7 +766,7 @@ extern struct BattleTestRunnerState *const gBattleTestRunnerState;
#define BATTLE_TEST_ARGS_DOUBLE(_name, _type, ...) \
struct CAT(Result, __LINE__) { RECURSIVELY(R_FOR_EACH(APPEND_SEMICOLON, __VA_ARGS__)) }; \
static void CAT(Test, __LINE__)(struct CAT(Result, __LINE__) *, const u32, struct BattlePokemon *, struct BattlePokemon *, struct BattlePokemon *, struct BattlePokemon *); \
__attribute__((section(".tests"))) static const struct Test CAT(sTest, __LINE__) = \
__attribute__((section(".tests"), used)) static const struct Test CAT(sTest, __LINE__) = \
{ \
.name = _name, \
.filename = __FILE__, \
Expand Down
4 changes: 2 additions & 2 deletions include/test/test.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ s32 Test_MgbaPrintf(const char *fmt, ...);

#define TEST(_name) \
static void CAT(Test, __LINE__)(void); \
__attribute__((section(".tests"))) static const struct Test CAT(sTest, __LINE__) = \
__attribute__((section(".tests"), used)) static const struct Test CAT(sTest, __LINE__) = \
{ \
.name = _name, \
.filename = __FILE__, \
Expand All @@ -95,7 +95,7 @@ s32 Test_MgbaPrintf(const char *fmt, ...);

#define ASSUMPTIONS \
static void Assumptions(void); \
__attribute__((section(".tests"))) static const struct Test sAssumptions = \
__attribute__((section(".tests"), used)) static const struct Test sAssumptions = \
{ \
.name = "ASSUMPTIONS: " __FILE__, \
.filename = __FILE__, \
Expand Down

0 comments on commit 09c424b

Please sign in to comment.