mirror of
https://github.com/friendica/friendica
synced 2025-04-20 17:50:12 +00:00
Reenable Twitter/Media Post tests
This commit is contained in:
parent
f84c696925
commit
204b8b6e49
5 changed files with 135 additions and 117 deletions
|
@ -126,6 +126,25 @@ abstract class ApiTest extends FixtureTest
|
|||
// We could probably do more checks here.
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the path to a temporary empty PNG image.
|
||||
*
|
||||
* @return string Path
|
||||
*/
|
||||
protected function getTempImage()
|
||||
{
|
||||
$tmpFile = tempnam(sys_get_temp_dir(), 'tmp_file');
|
||||
file_put_contents(
|
||||
$tmpFile,
|
||||
base64_decode(
|
||||
// Empty 1x1 px PNG image
|
||||
'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8/5+hHgAHggJ/PchI7wAAAABJRU5ErkJggg=='
|
||||
)
|
||||
);
|
||||
|
||||
return $tmpFile;
|
||||
}
|
||||
|
||||
/**
|
||||
* Transforms a response into a JSON class
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue