logging: adds clock scope (#1071)

Signed-off-by: Adrian Cole <adrian@tetrate.io>
This commit is contained in:
Crypt Keeper
2023-01-28 19:11:37 +02:00
committed by GitHub
parent bd9a791c7a
commit d944c3c70d
14 changed files with 312 additions and 94 deletions

View File

@@ -51,10 +51,11 @@ func TestLogScopes_String(t *testing.T) {
}{
{name: "none", scopes: LogScopeNone, expected: ""},
{name: "any", scopes: LogScopeAll, expected: "all"},
{name: "clock", scopes: LogScopeClock, expected: "clock"},
{name: "filesystem", scopes: LogScopeFilesystem, expected: "filesystem"},
{name: "random", scopes: LogScopeRandom, expected: "random"},
{name: "filesystem|random", scopes: LogScopeFilesystem | LogScopeRandom, expected: "filesystem|random"},
{name: "undefined", scopes: 1 << 3, expected: fmt.Sprintf("<unknown=%d>", (1 << 3))},
{name: "undefined", scopes: 1 << 14, expected: fmt.Sprintf("<unknown=%d>", 1<<14)},
}
for _, tt := range tests {