package game import "testing" func TestItemStrings(t *testing.T) { cases := []struct { item item want string }{ {itemNone, ""}, {itemLens, "🔍"}, {itemCig, "🚬"}, {itemBeer, "🍺"}, {itemCuff, "👮"}, {itemKnife, "🔪"}, } for _, c := range cases { got := c.item.String() if got != c.want { t.Errorf("Item(%d).String() == %q, want %q", c.item, got, c.want) } } }