Skip to content

Commit

Permalink
Add tests for new Signal
Browse files Browse the repository at this point in the history
  • Loading branch information
theseer committed Dec 1, 2023
1 parent 01cb296 commit 1297fc9
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/SignalTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,28 @@
#[CoversClass(Signal::class)]
#[CoversClass(Ignore::class)]
#[CoversClass(Remove::class)]
#[CoversClass(NotDefined::class)]
#[Small]
class SignalTest extends TestCase {

public function testCanCreateIgnoreSignal(): void {
$inst = Signal::ignore();
$this->assertTrue($inst->isIgnore());
$this->assertFalse($inst->isRemove());
$this->assertFalse($inst->isNotDefined());
}

public function testCanCreateRemoveSignal(): void {
$inst = Signal::remove();
$this->assertTrue($inst->isRemove());
$this->assertFalse($inst->isIgnore());
$this->assertFalse($inst->isNotDefined());
}

public function testCanCreateNotDefinedSignal(): void {
$inst = Signal::notDefined();
$this->assertTrue($inst->isNotDefined());
$this->assertFalse($inst->isRemove());
$this->assertFalse($inst->isIgnore());
}
}

0 comments on commit 1297fc9

Please sign in to comment.