@@ -128,7 +128,7 @@ public function testAfterSaveGiftMessages()
128128
129129 /**
130130 * @expectedException \Magento\Framework\Exception\CouldNotSaveException
131- * @expectedMessage The gift message couldn't be added to the "Test message" order.
131+ * @expectedExceptionMessage The gift message couldn't be added to the "Test message" order.
132132 */
133133 public function testAfterSaveIfGiftMessagesNotExist ()
134134 {
@@ -146,7 +146,7 @@ public function testAfterSaveIfGiftMessagesNotExist()
146146 $ this ->giftMessageOrderRepositoryMock
147147 ->expects ($ this ->once ())
148148 ->method ('save ' )
149- ->willThrowException (new \Exception ('TestMessage ' ));
149+ ->willThrowException (new \Exception ('Test message ' ));
150150
151151 // save Gift Messages on item level
152152 $ this ->orderMock ->expects ($ this ->never ())->method ('getItems ' );
@@ -155,7 +155,7 @@ public function testAfterSaveIfGiftMessagesNotExist()
155155
156156 /**
157157 * @expectedException \Magento\Framework\Exception\CouldNotSaveException
158- * @expectedMessage The gift message couldn't be added to the "Test message" order.
158+ * @expectedExceptionMessage The gift message couldn't be added to the "Test message" order item .
159159 */
160160 public function testAfterSaveIfItemGiftMessagesNotExist ()
161161 {
@@ -185,7 +185,7 @@ public function testAfterSaveIfItemGiftMessagesNotExist()
185185 $ this ->giftMessageOrderItemRepositoryMock
186186 ->expects ($ this ->once ())->method ('save ' )
187187 ->with ($ orderId , $ orderItemId , $ this ->giftMessageMock )
188- ->willThrowException (new \Exception ('TestMessage ' ));
188+ ->willThrowException (new \Exception ('Test message ' ));
189189 $ this ->plugin ->afterSave ($ this ->orderRepositoryMock , $ this ->orderMock );
190190 }
191191}
0 commit comments