-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add unit test for OneLoginForm and fix failing api-app test
- Loading branch information
Showing
2 changed files
with
43 additions
and
2 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
38 changes: 38 additions & 0 deletions
38
service-front/app/test/ActorTest/Form/OneLoginFormTest.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,38 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace ActorTest\Form; | ||
|
||
use Actor\Form\OneLoginForm; | ||
use Common\Form\AbstractForm; | ||
use Common\Form\Element\Csrf; | ||
use CommonTest\Form\LaminasFormTests; | ||
use CommonTest\Form\TestsLaminasForm; | ||
use PHPUnit\Framework\TestCase; | ||
use Prophecy\PhpUnit\ProphecyTrait; | ||
|
||
class OneLoginFormTest extends TestCase implements TestsLaminasForm | ||
{ | ||
use LaminasFormTests; | ||
use ProphecyTrait; | ||
|
||
protected OneLoginForm $form; | ||
|
||
public function getForm(): AbstractForm | ||
{ | ||
return $this->form; | ||
} | ||
|
||
public function getFormName(): string | ||
{ | ||
return 'one_login'; | ||
} | ||
|
||
public function getFormElements(): array | ||
{ | ||
return [ | ||
'__csrf' => Csrf::class, | ||
]; | ||
} | ||
} |