mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-05 14:20:22 +00:00
test: dedupe config and utility suites
This commit is contained in:
@@ -2,9 +2,11 @@ import { describe, expect, it } from "vitest";
|
||||
import { parseCliLogLevelOption } from "./log-level-option.js";
|
||||
|
||||
describe("parseCliLogLevelOption", () => {
|
||||
it("accepts allowed log levels", () => {
|
||||
expect(parseCliLogLevelOption("debug")).toBe("debug");
|
||||
expect(parseCliLogLevelOption(" trace ")).toBe("trace");
|
||||
it.each([
|
||||
["debug", "debug"],
|
||||
[" trace ", "trace"],
|
||||
] as const)("accepts allowed log level %p", (input, expected) => {
|
||||
expect(parseCliLogLevelOption(input)).toBe(expected);
|
||||
});
|
||||
|
||||
it("rejects invalid log levels", () => {
|
||||
|
||||
Reference in New Issue
Block a user