diff options
| author | Laytan Laats <laytanlaats@hotmail.com> | 2024-06-07 15:13:09 +0200 |
|---|---|---|
| committer | Laytan Laats <laytanlaats@hotmail.com> | 2024-06-07 15:13:09 +0200 |
| commit | ee93d7c05e563512ea41b00cc1347eb59427c500 (patch) | |
| tree | be001d7f30c3e5124d270369cea85330113eac24 /core/testing | |
| parent | 68781f8dd365692aee55099d3e14cb83a115764c (diff) | |
add error message for unknown test log level
It would previously just be a compilation error about a missing
return statement.
Diffstat (limited to 'core/testing')
| -rw-r--r-- | core/testing/runner.odin | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/testing/runner.odin b/core/testing/runner.odin index c82aa1fda..328186c35 100644 --- a/core/testing/runner.odin +++ b/core/testing/runner.odin @@ -53,6 +53,9 @@ get_log_level :: #force_inline proc() -> runtime.Logger_Level { else when LOG_LEVEL == "warning" { return .Warning } else when LOG_LEVEL == "error" { return .Error } else when LOG_LEVEL == "fatal" { return .Fatal } + else { + #panic("Unknown `ODIN_TEST_LOG_LEVEL`: \"" + LOG_LEVEL + "\", possible levels are: \"debug\", \"info\", \"warning\", \"error\", or \"fatal\".") + } } } |