diff --git a/tests/legacy/ApiTest.php b/tests/legacy/ApiTest.php index 743af75e0a..e7fba6583e 100644 --- a/tests/legacy/ApiTest.php +++ b/tests/legacy/ApiTest.php @@ -1189,44 +1189,7 @@ class ApiTest extends FixtureTest // self::assertArrayHasKey('user', $result); } - /** - * Test the api_direct_messages_box() function. - * - * @return void - */ - public function testApiDirectMessagesBoxWithSentbox() - { - /* - $_REQUEST['page'] = -1; - $_REQUEST['max_id'] = 10; - $result = api_direct_messages_box('json', 'sentbox', 'false'); - self::assertArrayHasKey('direct_message', $result); - */ - } - /** - * Test the api_direct_messages_box() function. - * - * @return void - */ - public function testApiDirectMessagesBoxWithConversation() - { - //$result = api_direct_messages_box('json', 'conversation', 'false'); - //self::assertArrayHasKey('direct_message', $result); - } - - - - /** - * Test the api_direct_messages_conversation() function. - * - * @return void - */ - public function testApiDirectMessagesConversation() - { - //$result = api_direct_messages_conversation('json'); - //self::assertArrayHasKey('direct_message', $result); - } /** * Test the api_oauth_request_token() function. diff --git a/tests/src/Module/Api/Twitter/DirectMessages/ConversationTest.php b/tests/src/Module/Api/Twitter/DirectMessages/ConversationTest.php new file mode 100644 index 0000000000..815d5eb577 --- /dev/null +++ b/tests/src/Module/Api/Twitter/DirectMessages/ConversationTest.php @@ -0,0 +1,32 @@ + Router::GET], ['extension' => 'json']); + $response = $sent->run([ + 'friendica_verbose' => true, + ]); + + $json = $this->toJson($response); + + self::assertEquals('error', $json->result); + self::assertEquals('no mails available', $json->message); + } +}