yield 'Test absolute discount for one item' =>
[ new ContainerItem([ new QuantityItem(20,
new HighTaxes()),
new AbsoluteItem(-10
),
]),
new CalculatedPrice(10, 10,
new CalculatedTaxes([19 => 1.59
]),
new HighTaxes()),
];
yield 'Test discount calculation for two items' =>
[ new ContainerItem([ new QuantityItem(20,
new HighTaxes()),
new QuantityItem(20,
new LowTaxes()),
new PercentageItem(-10
),
]),
new CalculatedPrice(36, 36,
new CalculatedTaxes([19 => 2.87, 7 => 1.18
]),
new HighTaxes()),
];
yield 'Test discount calculation with random order' =>
[ new ContainerItem([ new QuantityItem(20,
new LowTaxes()),
new PercentageItem(-10
),
new QuantityItem(20,
new HighTaxes()),
]),