Conditions | 1 |
Paths | 1 |
Total Lines | 19 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
19 | public function test_newchatmember_success() { |
||
20 | $data = [ |
||
21 | 'message' => [ |
||
22 | 'chat' => [ |
||
23 | 'id' => 133433434 |
||
24 | ], |
||
25 | 'new_chat_member' => [ |
||
26 | 'id' => 12345678, |
||
27 | 'first_name' => 'AlexR1712' |
||
28 | ] |
||
29 | ] |
||
30 | ]; |
||
31 | |||
32 | $body = json_encode($data); |
||
33 | $r = $this->client->request('POST', 'webhook.php', ['body' => $body]); |
||
34 | print($r->getBody()); |
||
35 | file_put_contents('test', $r->getBody()); |
||
36 | $this->assertEquals(200, $r->getStatusCode()); |
||
37 | } |
||
38 | |||
39 | } |