-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0ea5f9d
commit 2e74a84
Showing
25 changed files
with
413 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
packages/cookies-bundle/tests/Integration/CookiesPageAdminTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
/* | ||
* This file is part of the Runroom package. | ||
* | ||
* (c) Runroom <runroom@runroom.com> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
namespace Runroom\CookiesPageBundle\Tests\Integration; | ||
|
||
use Runroom\CookiesBundle\Admin\CookiesPageAdmin; | ||
use Runroom\Testing\TestCase\SonataAdminTestCase; | ||
|
||
class CookiesPageAdminTest extends SonataAdminTestCase | ||
{ | ||
/** @test */ | ||
public function itHasAllFormFields(): void | ||
{ | ||
$this->assertAdminFormContainsField('translations'); | ||
} | ||
|
||
/** @test */ | ||
public function itDoesNotHaveDisabledRoutes(): void | ||
{ | ||
$this->assertAdminRoutesDoesContainRoute('edit'); | ||
$this->assertAdminRoutesDoesNotContainRoute('show'); | ||
$this->assertAdminRoutesDoesNotContainRoute('delete'); | ||
$this->assertAdminRoutesDoesNotContainRoute('list'); | ||
$this->assertAdminRoutesDoesNotContainRoute('batch'); | ||
$this->assertAdminRoutesDoesNotContainRoute('export'); | ||
} | ||
|
||
protected function getAdminClass(): string | ||
{ | ||
return CookiesPageAdmin::class; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
56 changes: 56 additions & 0 deletions
56
packages/redirection-bundle/tests/Integration/RedirectAdminTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
/* | ||
* This file is part of the Runroom package. | ||
* | ||
* (c) Runroom <runroom@runroom.com> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
namespace Runroom\RedirectionBundle\Tests\Integration; | ||
|
||
use Runroom\RedirectionBundle\Admin\RedirectAdmin; | ||
use Runroom\Testing\TestCase\SonataAdminTestCase; | ||
|
||
class RedirectAdminTest extends SonataAdminTestCase | ||
{ | ||
/** @test */ | ||
public function itHasAllListFields(): void | ||
{ | ||
$this->assertAdminListContainsField('source'); | ||
$this->assertAdminListContainsField('destination'); | ||
$this->assertAdminListContainsField('httpCode'); | ||
$this->assertAdminListContainsField('publish'); | ||
$this->assertAdminListContainsField('automatic'); | ||
$this->assertAdminListContainsField('_action'); | ||
} | ||
|
||
/** @test */ | ||
public function itHasAllFormFields(): void | ||
{ | ||
$this->assertAdminFormContainsField('source'); | ||
$this->assertAdminFormContainsField('destination'); | ||
$this->assertAdminFormContainsField('httpCode'); | ||
$this->assertAdminFormContainsField('publish'); | ||
$this->assertAdminFormContainsField('automatic'); | ||
} | ||
|
||
/** @test */ | ||
public function itHasAllFilterFields(): void | ||
{ | ||
$this->assertAdminFilterContainsField('source'); | ||
$this->assertAdminFilterContainsField('destination'); | ||
$this->assertAdminFilterContainsField('httpCode'); | ||
$this->assertAdminFilterContainsField('automatic'); | ||
$this->assertAdminFilterContainsField('publish'); | ||
} | ||
|
||
protected function getAdminClass(): string | ||
{ | ||
return RedirectAdmin::class; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.