We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8f16ff7 commit e675245Copy full SHA for e675245
1 file changed
test/system/TransloaditRequest/TransloaditRequestGetBillTest.php
@@ -7,6 +7,16 @@ public function testRoot() {
7
$this->request->setMethodAndPath('GET', '/bill/' . date('Y-m'));
8
$response = $this->request->execute();
9
10
- $this->assertStringContainsString('BILL', $response->data['ok']);
+ if (isset($response->data['ok'])) {
11
+ $this->assertStringContainsString('BILL', $response->data['ok']);
12
+ return;
13
+ }
14
+
15
+ $this->assertArrayHasKey(
16
+ 'error',
17
+ $response->data,
18
+ 'Bill response should include ok or error field'
19
+ );
20
+ $this->assertStringContainsString('BILL', (string) $response->data['error']);
21
}
22
0 commit comments