File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
app/code/Magento/CatalogRule/Test/Unit/Pricing/Price Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -208,12 +208,20 @@ public function testGetValue()
208
208
209
209
public function testGetValueFromData ()
210
210
{
211
+ $ catalogRulePrice = 7.1 ;
212
+ $ convertedPrice = 5.84 ;
213
+
214
+ $ this ->priceCurrencyMock ->expects ($ this ->any ())
215
+ ->method ('convertAndRound ' )
216
+ ->with ($ catalogRulePrice )
217
+ ->will ($ this ->returnValue ($ convertedPrice ));
218
+
211
219
$ this ->saleableItemMock ->expects ($ this ->once ())->method ('hasData ' )
212
220
->with ('catalog_rule_price ' )->willReturn (true );
213
221
$ this ->saleableItemMock ->expects ($ this ->once ())->method ('getData ' )
214
- ->with ('catalog_rule_price ' )->willReturn (' 7.1 ' );
222
+ ->with ('catalog_rule_price ' )->willReturn ($ catalogRulePrice );
215
223
216
- $ this ->assertEquals (7.1 , $ this ->object ->getValue ());
224
+ $ this ->assertEquals ($ convertedPrice , $ this ->object ->getValue ());
217
225
}
218
226
219
227
public function testGetAmountNoBaseAmount ()
You can’t perform that action at this time.
0 commit comments