mirror of
https://github.com/pterodactyl/panel.git
synced 2026-12-01 11:55:51 -05:00
27 lines
835 B
PHP
27 lines
835 B
PHP
<?php
|
|||
|
|
|
||
|
|
namespace Pterodactyl\Tests\Integration\Api\Application\Servers;
|
||
|
|
|
||
|
|
use Pterodactyl\Tests\Integration\Api\Application\ApplicationApiIntegrationTestCase;
|
||
|
|
|
||
|
|
class ServerControllerTest extends ApplicationApiIntegrationTestCase
|
||
|
|
{
|
||
|
|
/**
|
||
|
|
* Test that the "skip scripts" state is returned for a server.
|
||
|
|
*/
|
||
|
|
public function testSkipScriptsStateIsReturned()
|
||
|
|
{
|
||
|
|
$server = $this->createServerModel(['skip_scripts' => true]);
|
||
|
|
|
||
|
|
$this->getJson('/api/application/servers/' . $server->id)
|
||
|
|
->assertOk()
|
||
|
|
->assertJsonPath('attributes.container.skip_scripts', true);
|
||
|
|
|
||
|
|
$server->update(['skip_scripts' => false]);
|
||
|
|
|
||
|
|
$this->getJson('/api/application/servers/' . $server->id)
|
||
|
|
->assertOk()
|
||
|
|
->assertJsonPath('attributes.container.skip_scripts', false);
|
||
|
|
}
|
||
|
|
}
|