@@ -33,13 +33,6 @@ class ProductPriceWithFPTTest extends GraphQlAbstract
33
33
/** @var ScopeConfigInterface */
34
34
private $ scopeConfig ;
35
35
36
-
37
- /** @var \Magento\Tax\Model\Calculation\Rate[] */
38
- private $ fixtureTaxRates ;
39
-
40
- /** @var \Magento\Tax\Model\Calculation\Rule[] */
41
- private $ fixtureTaxRules ;
42
-
43
36
/**
44
37
* @inheritdoc
45
38
*/
@@ -59,20 +52,6 @@ protected function setUp(): void
59
52
'tax/calculation/price_includes_tax '
60
53
];
61
54
62
-
63
- $ this ->getFixtureTaxRates ();
64
- $ this ->getFixtureTaxRules ();
65
- $ taxRules = $ this ->getFixtureTaxRules ();
66
- if (count ($ taxRules )) {
67
- $ taxRates = $ this ->getFixtureTaxRates ();
68
- foreach ($ taxRules as $ taxRule ) {
69
- $ taxRule ->delete ();
70
- }
71
- foreach ($ taxRates as $ taxRate ) {
72
- $ taxRate ->delete ();
73
- }
74
- }
75
-
76
55
foreach ($ currentSettingsArray as $ configPath ) {
77
56
$ this ->initialConfig [$ configPath ] = $ this ->scopeConfig ->getValue (
78
57
$ configPath
@@ -546,7 +525,7 @@ public function catalogPriceIncTaxCatalogDisplayInclTaxInclFPTWithDescrWithTaxAp
546
525
return [
547
526
[
548
527
'weeTaxSettings ' => [
549
- 'tax/calculation/price_includes_tax ' > '1 ' ,
528
+ 'tax/calculation/price_includes_tax ' = > '1 ' ,
550
529
'tax/display/type ' => '2 ' ,
551
530
'tax/weee/enable ' => '1 ' ,
552
531
'tax/weee/display ' => '0 ' ,
@@ -762,47 +741,4 @@ private function getProductQuery(array $skus): string
762
741
}
763
742
QUERY ;
764
743
}
765
-
766
- /**
767
- * Get tax rates created in Magento\Tax\_files\tax_rule_region_1_al.php
768
- *
769
- * @return \Magento\Tax\Model\Calculation\Rate[]
770
- */
771
- private function getFixtureTaxRates ()
772
- {
773
- if ($ this ->fixtureTaxRates === null ) {
774
- $ this ->fixtureTaxRates = [];
775
- if ($ this ->getFixtureTaxRules ()) {
776
- $ taxRateIds = (array )$ this ->getFixtureTaxRules ()[0 ]->getRates ();
777
- foreach ($ taxRateIds as $ taxRateId ) {
778
- /** @var \Magento\Tax\Model\Calculation\Rate $taxRate */
779
- $ taxRate = Bootstrap::getObjectManager ()->create (\Magento \Tax \Model \Calculation \Rate::class);
780
- $ this ->fixtureTaxRates [] = $ taxRate ->load ($ taxRateId );
781
- }
782
- }
783
- }
784
- return $ this ->fixtureTaxRates ;
785
- }
786
-
787
- /**
788
- * Get tax rule created in Magento\Tax\_files\tax_rule_region_1_al.php
789
- *
790
- * @return \Magento\Tax\Model\Calculation\Rule[]
791
- */
792
- private function getFixtureTaxRules ()
793
- {
794
- if ($ this ->fixtureTaxRules === null ) {
795
- $ this ->fixtureTaxRules = [];
796
- $ taxRuleCodes = ['AL Test Rule ' ];
797
- foreach ($ taxRuleCodes as $ taxRuleCode ) {
798
- /** @var \Magento\Tax\Model\Calculation\Rule $taxRule */
799
- $ taxRule = Bootstrap::getObjectManager ()->create (\Magento \Tax \Model \Calculation \Rule::class);
800
- $ taxRule ->load ($ taxRuleCode , 'code ' );
801
- if ($ taxRule ->getId ()) {
802
- $ this ->fixtureTaxRules [] = $ taxRule ;
803
- }
804
- }
805
- }
806
- return $ this ->fixtureTaxRules ;
807
- }
808
744
}
0 commit comments