Skip to content

Commit

Permalink
Migrate phpunit metadata to attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
tvdijen committed Apr 30, 2024
1 parent 26df41d commit 06604cf
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
4 changes: 2 additions & 2 deletions tests/src/Controller/DiscoPowerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

namespace SimpleSAML\Test\Module\discopower\Controller;

use PHPUnit\Framework\Attributes\CoversClass;
use SimpleSAML\Configuration;
use SimpleSAML\Error;
use SimpleSAML\HTTP\RunnableResponse;
Expand All @@ -14,9 +15,8 @@

/**
* Set of tests for the controllers in the "discopwer" module.
*
* @covers \SimpleSAML\Module\discopower\Controller\DiscoPower
*/
#[CoversClass(Controller\DiscoPower::class)]
class DiscoPowerTest extends ClearStateTestCase
{
/** @var \SimpleSAML\Configuration */
Expand Down
9 changes: 2 additions & 7 deletions tests/src/PowerIdPDiscoTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,14 @@

namespace SimpleSAML\Test\Module\discopower;

use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;
use ReflectionClass;
use SimpleSAML\Configuration;
use SimpleSAML\Metadata\MetaDataStorageHandler;
use SimpleSAML\Module\discopower\PowerIdPDisco;

#[CoversClass(PowerIdPDisco::Class)]

Check failure on line 14 in tests/src/PowerIdPDiscoTest.php

View workflow job for this annotation

GitHub Actions / Quality control

UndefinedConstant

tests/src/PowerIdPDiscoTest.php:14:15: UndefinedConstant: Constant SimpleSAML\Module\discopower\PowerIdPDisco::Class is not defined (see https://psalm.dev/020)
class PowerIdPDiscoTest extends TestCase
{
/** @var \SimpleSAML\Module\discopower\PowerIdPDisco */
Expand Down Expand Up @@ -53,16 +55,13 @@ public static function setUpBeforeClass(): void
}

/**
* @covers \SimpleSAML\Module\discopower\PowerIdPDisco
* @covers \SimpleSAML\Module\discopower\PowerIdPDisco::__construct
*/
public function testPowerIdPDisco(): void
{
$this->assertInstanceOf(PowerIdPDisco::class, self::$discoHandler);
}

/**
* @covers \SimpleSAML\Module\discopower\PowerIdPDisco::getIdPList
*/
public function testGetIdPList(): void
{
Expand All @@ -75,9 +74,6 @@ public function testGetIdPList(): void
}

/**
* @covers \SimpleSAML\Module\discopower\PowerIdPDisco::idplistStructured
* @covers \SimpleSAML\Module\discopower\PowerIdPDisco::getIdPList
* @covers \SimpleSAML\Module\discopower\PowerIdPDisco::mcmp
*/
public function testIdplistStructured(): void
{
Expand Down Expand Up @@ -137,7 +133,6 @@ public function testIdplistStructured(): void
}

/**
* @covers \SimpleSAML\Module\discopower\PowerIdPDisco::mcmp
*/
public function testmcmp(): void
{
Expand Down

0 comments on commit 06604cf

Please sign in to comment.