Skip to content

Commit 1008918

Browse files
committed
Fix tests for isDark
1 parent 794826e commit 1008918

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

src/test/bin/colorDecisions/parseColorDecisionName.test.ts

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { same } from "evt/tools/inDepth/same";
55

66
console.log(`Running test ${__filename}`);
77

8-
const colorNames = ["grey", "orangeTerreBattue"];
8+
const colorNames = ["grey", "orangeTerreBattue", "blueFrance"];
99

1010
const { parseColorDecisionName } = createParseColorDecisionName({ colorNames });
1111

@@ -88,3 +88,19 @@ const { parseColorDecisionName } = createParseColorDecisionName({ colorNames });
8888

8989
console.log("PASS 5");
9090
}
91+
92+
{
93+
const expected: ParsedColorDecisionName = {
94+
"context": "background",
95+
"usage": "action",
96+
"variant": "high",
97+
"colorName": "blueFrance",
98+
"state": undefined
99+
};
100+
101+
const got = parseColorDecisionName("--background-action-high-blue-france");
102+
103+
assert(same(got, expected));
104+
105+
console.log("PASS 6");
106+
}

0 commit comments

Comments
 (0)