1
0
Fork 0
This commit is contained in:
root 2018-12-17 14:36:56 +00:00 committed by Hypolite Petovan
parent 6c2ace3cab
commit 9c90cf7caf

View file

@ -1405,6 +1405,19 @@ class ApiTest extends DatabaseTest
}
}
/**
* Test the api_search() function with an q parameter contains hashtag.
* @return void
*/
public function testApiSearchWithHashtag()
{
$_REQUEST['q'] = '#friendica';
$result = api_search('json');
foreach ($result['status'] as $status) {
$this->assertStatus($status);
$this->assertContains('#friendica', $status['text'], null, true);
}
}
/**
* Test the api_search() function without an authenticated user.