File tree Expand file tree Collapse file tree 3 files changed +10
-13
lines changed Expand file tree Collapse file tree 3 files changed +10
-13
lines changed Original file line number Diff line number Diff line change @@ -93,8 +93,7 @@ public function getConfig(string $page): array
93
93
'isGuestCheckoutAllowed ' => $ isGuestCheckoutAllowed ,
94
94
'sdkUrl ' => $ this ->sdkUrl ->getUrl (),
95
95
'dataAttributes ' => [
96
- 'data-partner-attribution-id ' => $ config ->getBuildNotationCode () != '' ?
97
- $ config ->getBuildNotationCode () : ''
96
+ 'data-partner-attribution-id ' => ($ config ) ? $ config ->getBuildNotationCode () : ''
98
97
]
99
98
];
100
99
}
Original file line number Diff line number Diff line change @@ -48,13 +48,11 @@ class SmartButtonConfigTest extends TestCase
48
48
*/
49
49
protected function setUp (): void
50
50
{
51
- $ this ->localeResolverMock = $ this ->getMockForAbstractClass (ResolverInterface::class);
52
- $ this ->configMock = $ this ->getMockBuilder (Config::class)
51
+ $ this ->localeResolverMock = $ this ->getMockForAbstractClass (ResolverInterface::class);
52
+ $ this ->configMock = $ this ->getMockBuilder (Config::class)
53
53
->disableOriginalConstructor ()
54
54
->getMock ();
55
-
56
- $ this ->payflowproMock = $ this ->getMockBuilder (Payflowpro::class)
57
- ->getMock ();
55
+ $ this ->payflowproMock = $ this ->createMock (Payflowpro::class);
58
56
59
57
/** @var ScopeConfigInterface|MockObject $scopeConfigMock */
60
58
$ scopeConfigMock = $ this ->getMockForAbstractClass (ScopeConfigInterface::class);
@@ -76,8 +74,8 @@ protected function setUp(): void
76
74
$ configFactoryMock ,
77
75
$ scopeConfigMock ,
78
76
$ sdkUrl ,
79
- $ this ->getDefaultStyles () ,
80
- $ this ->payflowproMock
77
+ $ this ->payflowproMock ,
78
+ $ this ->getDefaultStyles ()
81
79
);
82
80
}
83
81
Original file line number Diff line number Diff line change 29
29
'isGuestCheckoutAllowed ' => true ,
30
30
'sdkUrl ' => 'http://mock.url ' ,
31
31
'dataAttributes ' => [
32
- 'data-partner-attribution-id ' => 'Magento_2_%s '
32
+ 'data-partner-attribution-id ' => ''
33
33
]
34
34
]
35
35
],
56
56
'isGuestCheckoutAllowed ' => true ,
57
57
'sdkUrl ' => 'http://mock.url ' ,
58
58
'dataAttributes ' => [
59
- 'data-partner-attribution-id ' => 'Magento_2_%s '
59
+ 'data-partner-attribution-id ' => ''
60
60
]
61
61
]
62
62
],
82
82
'isGuestCheckoutAllowed ' => true ,
83
83
'sdkUrl ' => 'http://mock.url ' ,
84
84
'dataAttributes ' => [
85
- 'data-partner-attribution-id ' => 'Magento_2_%s '
85
+ 'data-partner-attribution-id ' => ''
86
86
]
87
87
]
88
88
],
108
108
'isGuestCheckoutAllowed ' => true ,
109
109
'sdkUrl ' => 'http://mock.url ' ,
110
110
'dataAttributes ' => [
111
- 'data-partner-attribution-id ' => 'Magento_2_%s '
111
+ 'data-partner-attribution-id ' => ''
112
112
]
113
113
]
114
114
],
You can’t perform that action at this time.
0 commit comments