We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5096a2b commit c4a2882Copy full SHA for c4a2882
tests/test_ansi.py
@@ -136,6 +136,13 @@ def test_color_str_building():
136
fg.blue.value + bg.white.value + "hello" + fg.reset.value + bg.reset.value
137
138
139
+def test_color_nonunique_values():
140
+ class Matching(ansi.ColorBase):
141
+ magenta = ansi.fg_lookup('magenta')
142
+ purple = ansi.fg_lookup('magenta')
143
+ assert sorted(Matching.colors()) == ['magenta', 'purple']
144
+
145
146
def test_color_enum():
147
assert ansi.fg_lookup('bright_red') == ansi.fg_lookup(ansi.fg.bright_red)
148
assert ansi.bg_lookup('green') == ansi.bg_lookup(ansi.bg.green)
0 commit comments