File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
dev/tests/api-functional/testsuite/Magento/GraphQl/Sales Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change 7
7
8
8
namespace Magento \GraphQl \Sales ;
9
9
10
+ use Exception ;
10
11
use Magento \Integration \Api \CustomerTokenServiceInterface ;
11
12
use Magento \TestFramework \TestCase \GraphQlAbstract ;
12
13
use Magento \TestFramework \Helper \Bootstrap ;
@@ -99,6 +100,25 @@ public function testOrdersQuery()
99
100
}
100
101
}
101
102
103
+ /**
104
+ * @expectedException Exception
105
+ * @expectedExceptionMessage The current customer isn't authorized.
106
+ */
107
+ public function testOrdersQueryNotAuthorized ()
108
+ {
109
+ $ query = <<<QUERY
110
+ {
111
+ customerOrders {
112
+ items {
113
+ increment_id
114
+ grand_total
115
+ }
116
+ }
117
+ }
118
+ QUERY ;
119
+ $ this ->graphQlQuery ($ query );
120
+ }
121
+
102
122
/**
103
123
* @param string $email
104
124
* @param string $password
You can’t perform that action at this time.
0 commit comments