Code style and test updates.

This commit is contained in:
Buster "Silver Eagle" Neece 2021-08-12 08:30:59 -05:00
parent 75257caee2
commit 1d7ed8038a
No known key found for this signature in database
GPG Key ID: 6D9E12FF03411F4E
3 changed files with 2 additions and 20 deletions

View File

@ -112,7 +112,7 @@ class RemotesController extends AbstractStationApiCrudController
$returnArray = $this->toArray($record);
$return = new Entity\Api\StationRemote;
$return = new Entity\Api\StationRemote();
$return->fromParentObject($returnArray);
$isInternal = ('true' === $request->getParam('internal', 'false'));

View File

@ -11,6 +11,7 @@ use GuzzleHttp\Client;
use Monolog\Logger;
use Psr\SimpleCache\CacheInterface;
use RuntimeException;
use const JSON_PRETTY_PRINT;
class LocalWebhookHandler

View File

@ -8,30 +8,11 @@ class Station_RemoteRelaysCest extends CestAbstract
*/
public function editRemoteRelays(FunctionalTester $I): void
{
$I->wantTo('Create a station remote relay.');
$testStation = $this->getTestStation();
$station_id = $testStation->getId();
$I->amOnPage('/station/' . $station_id . '/remotes');
$I->see('Remote Relays');
$I->click('Add Remote Relay', '#content');
$I->submitForm('.form', [
'type' => 'shoutcast1',
'url' => 'http://test.local',
'display_name' => 'Test Relay',
]);
$I->seeCurrentUrlEquals('/station/' . $station_id . '/remotes');
$I->see('Test Relay');
$I->click(\Codeception\Util\Locator::lastElement('.btn-danger'));
$I->seeCurrentUrlEquals('/station/' . $station_id . '/remotes');
$I->dontSee('Test Relay');
}
}