Apply fixes from StyleCI

This commit is contained in:
Daniil Gentili 2017-06-30 13:37:18 +00:00 committed by StyleCI Bot
parent 70a85cb6be
commit dddad90616
2 changed files with 31 additions and 31 deletions

View File

@ -73,8 +73,8 @@ $message = (getenv('TRAVIS_COMMIT') == '') ? 'I iz works always (io laborare sem
echo 'Serializing MadelineProto to session.madeline...'.PHP_EOL; echo 'Wrote
'.\danog\MadelineProto\Serialization::serialize('session.madeline', $MadelineProto).' bytes'.PHP_EOL;
if (stripos(readline('Do you want to make the secret chat tests? (y/n): '), 'y') !== false) {
$start = false;
var_dump($id = $MadelineProto->request_call('@danogentili', [
$start = false;
var_dump($id = $MadelineProto->request_call('@danogentili', [
'set_state' => function ($state) {
var_dump("SET STATE $state");
},
@ -106,7 +106,9 @@ var_dump($id = $MadelineProto->request_call('@danogentili', [
],
]));
while (!$start) $MadelineProto->get_updates();
while (!$start) {
$MadelineProto->get_updates();
}
$controller = $MadelineProto->get_call($id)['controller'];
$samplerate = 48000;
$period = 1 / $samplerate;
@ -127,10 +129,9 @@ while (!$start) $MadelineProto->get_updates();
var_dump('sent 960 frames');
}
while ($MadelineProto->call_status($id) !== \danog\MadelineProto\MTProto::READY) {
while ($MadelineProto->call_status($id) !== \danog\MadelineProto\MTProto::READY) {
$MadelineProto->get_updates();
}
}
var_dump(getenv('TEST_SECRET_CHAT'));
$secret = $MadelineProto->API->request_secret_chat(getenv('TEST_SECRET_CHAT'));
@ -199,7 +200,6 @@ $mention = $MadelineProto->get_info(getenv('TEST_USERNAME')); // Returns an arra
$mention = $mention['user_id']; // Selects only the numeric user id
$media = [];
// Sticker
$inputFile = $MadelineProto->upload('tests/lel.webp');
$media['sticker'] = ['_' => 'inputMediaUploadedDocument', 'file' => $inputFile, 'mime_type' => mime_content_type('tests/lel.webp'), 'caption' => 'test', 'attributes' => [['_' => 'documentAttributeSticker', 'alt' => 'LEL', 'stickerset' => ['_' => 'inputStickerSetEmpty']]]];