diff options
Diffstat (limited to 'internal/game/production_ingredients_test.go')
| -rw-r--r-- | internal/game/production_ingredients_test.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/game/production_ingredients_test.go b/internal/game/production_ingredients_test.go index d799df8..5206346 100644 --- a/internal/game/production_ingredients_test.go +++ b/internal/game/production_ingredients_test.go @@ -111,14 +111,14 @@ func TestCollectByproductsMatchesConsumedAlternative(t *testing.T) { // Only the jug is present: the empty jug returns. p := invOf(t, map[string]int{"jug_of_water": 1}) - if got := g.collectByproducts(p, &item.ItemDef{Craft: item.CraftList{*craft}}); len(got) != 1 || got[0] != "empty_jug" { + if got := g.collectByproducts(p, craft); len(got) != 1 || got[0] != "empty_jug" { t.Errorf("byproducts = %v, want [empty_jug]", got) } // Both present: consumption picks the FIRST alternative (the bucket), // so the byproduct must be the empty bucket. p = invOf(t, map[string]int{"bucket_of_water": 1, "jug_of_water": 1}) - if got := g.collectByproducts(p, &item.ItemDef{Craft: item.CraftList{*craft}}); len(got) != 1 || got[0] != "empty_bucket" { + if got := g.collectByproducts(p, craft); len(got) != 1 || got[0] != "empty_bucket" { t.Errorf("byproducts = %v, want [empty_bucket]", got) } } |
