Color tests now use rgb colors, instead of predefined ones.
@@ -15,23 +15,23 @@ func TestColorToHex(t *testing.T) {
}{
{
name: "black",
- color: tcell.ColorBlack,
+ color: tcell.NewRGBColor(0, 0, 0),
want: "#000000",
}, {
name: "white",
- color: tcell.ColorWhite,
+ color: tcell.NewRGBColor(255, 255, 255),
want: "#ffffff",
}, {
name: "red",
- color: tcell.ColorRed,
+ color: tcell.NewRGBColor(255, 0, 0),
want: "#ff0000",
}, {
name: "green",
- color: tcell.ColorRed,
+ color: tcell.NewRGBColor(0, 255, 0),
want: "#00ff00",
}, {
name: "blue",
- color: tcell.ColorRed,
+ color: tcell.NewRGBColor(0, 0, 255),
want: "#0000ff",
},
}
