File tree Expand file tree Collapse file tree 9 files changed +38
-4
lines changed
Analytics/Test/Unit/Model/Connector
Braintree/Test/Unit/Model/Paypal/Helper
Msrp/Test/Unit/Ui/DataProvider/Product/Listing/Collector
Controller/Adminhtml/Order/Create
Tax/Test/Unit/Ui/DataProvider/Product/Listing/Collector
Weee/Test/Unit/Ui/DataProvider/Product/Listing/Collector Expand file tree Collapse file tree 9 files changed +38
-4
lines changed Original file line number Diff line number Diff line change @@ -104,7 +104,9 @@ public function getTestData()
104
104
}
105
105
106
106
/**
107
+ * @param array $data
107
108
* @return void
109
+ * @throws \Zend_Http_Exception
108
110
* @dataProvider getTestData
109
111
*/
110
112
public function testRequestSuccess (array $ data )
@@ -145,7 +147,9 @@ public function testRequestSuccess(array $data)
145
147
}
146
148
147
149
/**
150
+ * @param array $data
148
151
* @return void
152
+ * @throws \Zend_Http_Exception
149
153
* @dataProvider getTestData
150
154
*/
151
155
public function testRequestError (array $ data )
Original file line number Diff line number Diff line change @@ -25,6 +25,9 @@ class JsonConverterTest extends \PHPUnit\Framework\TestCase
25
25
*/
26
26
private $ converter ;
27
27
28
+ /**
29
+ * @return void
30
+ */
28
31
protected function setUp ()
29
32
{
30
33
$ this ->objectManagerHelper = new \Magento \Framework \TestFramework \Unit \Helper \ObjectManager ($ this );
@@ -37,6 +40,9 @@ protected function setUp()
37
40
);
38
41
}
39
42
43
+ /**
44
+ * @return void
45
+ */
40
46
public function testConverterContainsHeader ()
41
47
{
42
48
$ this ->assertEquals (
@@ -69,6 +75,9 @@ public function convertBodyDataProvider()
69
75
];
70
76
}
71
77
78
+ /**
79
+ * return void
80
+ */
72
81
public function testConvertData ()
73
82
{
74
83
$ this ->serializerMock ->expects ($ this ->once ())
Original file line number Diff line number Diff line change @@ -57,6 +57,9 @@ class SignUpCommandTest extends \PHPUnit\Framework\TestCase
57
57
*/
58
58
private $ responseResolverMock ;
59
59
60
+ /**
61
+ * @return void
62
+ */
60
63
protected function setUp ()
61
64
{
62
65
$ this ->analyticsTokenMock = $ this ->getMockBuilder (AnalyticsToken::class)
@@ -91,6 +94,10 @@ protected function setUp()
91
94
);
92
95
}
93
96
97
+ /**
98
+ * @throws \Zend_Http_Exception
99
+ * @return void
100
+ */
94
101
public function testExecuteSuccess ()
95
102
{
96
103
$ this ->integrationManagerMock ->expects ($ this ->once ())
@@ -124,6 +131,9 @@ public function testExecuteSuccess()
124
131
$ this ->assertTrue ($ this ->signUpCommand ->execute ());
125
132
}
126
133
134
+ /**
135
+ * @return void
136
+ */
127
137
public function testExecuteFailureCannotGenerateToken ()
128
138
{
129
139
$ this ->integrationManagerMock ->expects ($ this ->once ())
@@ -134,6 +144,10 @@ public function testExecuteFailureCannotGenerateToken()
134
144
$ this ->assertFalse ($ this ->signUpCommand ->execute ());
135
145
}
136
146
147
+ /**
148
+ * @throws \Zend_Http_Exception
149
+ * @return void
150
+ */
137
151
public function testExecuteFailureResponseIsEmpty ()
138
152
{
139
153
$ this ->integrationManagerMock ->expects ($ this ->once ())
Original file line number Diff line number Diff line change @@ -300,7 +300,7 @@ private function getQuoteMock()
300
300
$ cartExtensionMock = $ this ->getMockBuilder (CartExtensionInterface::class)
301
301
->setMethods (['setShippingAssignments ' ])
302
302
->disableOriginalConstructor ()
303
- ->getMock ();
303
+ ->getMockForAbstractClass ();
304
304
305
305
$ quoteMock ->expects (self ::any ())
306
306
->method ('getExtensionAttributes ' )
Original file line number Diff line number Diff line change @@ -101,7 +101,7 @@ public function testCollect()
101
101
\Magento \Catalog \Api \Data \ProductRender \PriceInfoExtensionInterface::class
102
102
)
103
103
->setMethods (['setMsrp ' ])
104
- ->getMock ();
104
+ ->getMockForAbstractClass ();
105
105
106
106
$ priceInfo = $ this ->getMockBuilder (MsrpPriceInfoInterface::class)
107
107
->setMethods (['getPrice ' , 'getExtensionAttributes ' ])
Original file line number Diff line number Diff line change @@ -118,7 +118,9 @@ protected function setUp()
118
118
->getMock ();
119
119
$ this ->requestMock = $ this ->getMockBuilder (RequestInterface::class)->getMockForAbstractClass ();
120
120
$ this ->objectManagerMock = $ this ->getMockBuilder (ObjectManagerInterface::class)->getMockForAbstractClass ();
121
- $ this ->resultForwardFactoryMock = $ this ->getMockBuilder (ForwardFactory::class)->getMock ();
121
+ $ this ->resultForwardFactoryMock = $ this ->getMockBuilder (ForwardFactory::class)
122
+ ->disableOriginalConstructor ()
123
+ ->getMock ();
122
124
$ this ->resultRedirectFactoryMock = $ this ->getMockBuilder (RedirectFactory::class)
123
125
->disableOriginalConstructor ()
124
126
->getMock ();
Original file line number Diff line number Diff line change @@ -47,6 +47,7 @@ protected function setUp()
47
47
'storeManager ' => $ this ->storeManagerMock ,
48
48
]);
49
49
$ this ->statusFactoryMock = $ this ->getMockBuilder (\Magento \Sales \Model \Order \StatusFactory::class)
50
+ ->disableOriginalConstructor ()
50
51
->setMethods (['load ' , 'create ' ])
51
52
->getMock ();
52
53
$ this ->orderStatusCollectionFactoryMock = $ this ->createPartialMock (
Original file line number Diff line number Diff line change @@ -68,10 +68,12 @@ protected function setUp()
68
68
->getMockForAbstractClass ();
69
69
70
70
$ this ->priceInfoFactory = $ this ->getMockBuilder (PriceInfoInterfaceFactory::class)
71
+ ->disableOriginalConstructor ()
71
72
->setMethods (['create ' ])
72
73
->getMock ();
73
74
74
75
$ this ->priceInfoExtensionFactory = $ this ->getMockBuilder (PriceInfoExtensionInterfaceFactory::class)
76
+ ->disableOriginalConstructor ()
75
77
->setMethods (['create ' ])
76
78
->getMock ();
77
79
$ this ->formattedPriceInfoBuilder = $ this ->getMockBuilder (FormattedPriceInfoBuilder::class)
Original file line number Diff line number Diff line change @@ -50,14 +50,16 @@ protected function setUp()
50
50
->getMockForAbstractClass ();
51
51
52
52
$ this ->weeeAdjustmentAttributeFactory = $ this ->getMockBuilder (WeeeAdjustmentAttributeInterfaceFactory::class)
53
+ ->disableOriginalConstructor ()
53
54
->setMethods (['create ' ])
54
55
->getMock ();
55
56
56
57
$ this ->extensionAttributes = $ this ->getMockBuilder (PriceInfoExtensionInterface::class)
57
58
->setMethods (['setWeeeAttributes ' , 'setWeeeAdjustment ' ])
58
- ->getMock ();
59
+ ->getMockForAbstractClass ();
59
60
60
61
$ this ->priceInfoExtensionFactory = $ this ->getMockBuilder (PriceInfoExtensionInterfaceFactory::class)
62
+ ->disableOriginalConstructor ()
61
63
->setMethods (['create ' ])
62
64
->getMock ();
63
65
You can’t perform that action at this time.
0 commit comments