1package bug
2
3import (
4 "testing"
5
6 "github.com/stretchr/testify/require"
7)
8
9func TestLabelRGBA(t *testing.T) {
10 rgba := Label("test").Color()
11 expected := LabelColor{R: 255, G: 87, B: 34, A: 255}
12
13 require.Equal(t, expected, rgba)
14}
15
16func TestLabelRGBASimilar(t *testing.T) {
17 rgba := Label("test1").Color()
18 expected := LabelColor{R: 0, G: 188, B: 212, A: 255}
19
20 require.Equal(t, expected, rgba)
21}
22
23func TestLabelRGBAReverse(t *testing.T) {
24 rgba := Label("tset").Color()
25 expected := LabelColor{R: 233, G: 30, B: 99, A: 255}
26
27 require.Equal(t, expected, rgba)
28}
29
30func TestLabelRGBAEqual(t *testing.T) {
31 color1 := Label("test").Color()
32 color2 := Label("test").Color()
33
34 require.Equal(t, color1, color2)
35}