link user
Build and Publish / BuildAndDeployAmd64 (push) Failing after 4s
Build and Publish / BuildAndDeployArm64 (push) Failing after 5s

This commit is contained in:
2026-06-30 18:45:58 +02:00
parent 7b657901ac
commit 9495c654fa
5 changed files with 67 additions and 20 deletions
+14
View File
@@ -184,6 +184,13 @@ func TestBuyXGetYEffect(t *testing.T) {
if got := g.TotalPrice.IncVat; got != 2000 {
t.Errorf("total price = %d, want 2000", got)
}
if len(g.AppliedPromotions) != 1 {
t.Fatalf("expected 1 applied promotion, got %d", len(g.AppliedPromotions))
}
itemIds := g.AppliedPromotions[0].ItemIds
if len(itemIds) != 1 || itemIds[0] != 1 {
t.Errorf("expected affected itemIds [1], got %v", itemIds)
}
}
func TestBundleDiscountEffect(t *testing.T) {
@@ -247,4 +254,11 @@ func TestBundleDiscountEffect(t *testing.T) {
if got := g.TotalPrice.IncVat; got != 4000 {
t.Errorf("total price = %d, want 4000", got)
}
if len(g.AppliedPromotions) != 1 {
t.Fatalf("expected 1 applied promotion, got %d", len(g.AppliedPromotions))
}
itemIds := g.AppliedPromotions[0].ItemIds
if len(itemIds) != 2 || itemIds[0] != 1 || itemIds[1] != 2 {
t.Errorf("expected affected itemIds [1, 2], got %v", itemIds)
}
}