Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
magento2-base
dev
tests
api-functional
testsuite
Magento
Sales
Service
V1
OrderEmailTest.php
Go to the documentation of this file.
1
<?php
7
namespace
Magento\Sales\Service\V1
;
8
9
use
Magento\TestFramework\TestCase\WebapiAbstract
;
10
11
class
OrderEmailTest
extends
WebapiAbstract
12
{
13
const
SERVICE_VERSION
=
'V1'
;
14
15
const
SERVICE_NAME
=
'salesOrderManagementV1'
;
16
20
public
function
testOrderEmail
()
21
{
22
$order
=
\Magento\TestFramework\Helper\Bootstrap::getObjectManager
()
23
->create(\
Magento
\Sales\Model\Order::class);
24
$order
->loadByIncrementId(
'100000001'
);
25
$serviceInfo = [
26
'rest'
=> [
27
'resourcePath'
=>
'/V1/orders/'
.
$order
->getId() .
'/emails'
,
28
'httpMethod'
=>
\Magento\Framework\Webapi\Rest\Request::HTTP_METHOD_POST
,
29
],
30
'soap'
=> [
31
'service'
=>
self::SERVICE_NAME
,
32
'serviceVersion'
=>
self::SERVICE_VERSION
,
33
'operation'
=> self::SERVICE_NAME .
'notify'
,
34
],
35
];
36
$requestData
= [
'id'
=>
$order
->getId()];
37
$this->assertTrue($this->
_webApiCall
($serviceInfo,
$requestData
));
38
}
39
}
$requestData
$requestData
Definition:
order_configurable_product.php:31
Magento\TestFramework\TestCase\WebapiAbstract\_webApiCall
_webApiCall( $serviceInfo, $arguments=[], $webApiAdapterCode=null, $storeCode=null, $integration=null)
Definition:
WebapiAbstract.php:165
$order
$order
Definition:
order.php:55
Magento\Sales\Service\V1\OrderEmailTest\SERVICE_NAME
const SERVICE_NAME
Definition:
OrderEmailTest.php:15
Magento\Sales\Service\V1
Definition:
CreditmemoAddCommentTest.php:6
Magento\Sales\Service\V1\OrderEmailTest
Definition:
OrderEmailTest.php:11
Magento\Framework\Webapi\Rest\Request\HTTP_METHOD_POST
const HTTP_METHOD_POST
Definition:
Request.php:22
Magento
Magento\TestFramework\TestCase\WebapiAbstract
Definition:
WebapiAbstract.php:19
Magento\Sales\Service\V1\OrderEmailTest\testOrderEmail
testOrderEmail()
Definition:
OrderEmailTest.php:20
Magento\Sales\Service\V1\OrderEmailTest\SERVICE_VERSION
const SERVICE_VERSION
Definition:
OrderEmailTest.php:13
Magento\TestFramework\Helper\Bootstrap\getObjectManager
static getObjectManager()
Definition:
Bootstrap.php:125