This commit is contained in:
@@ -17,11 +17,13 @@ final class SchoolYearContextTest extends CIUnitTestCase
|
||||
$this->assertSame('2025-2026', $context->yearName());
|
||||
}
|
||||
|
||||
public function testClosedAndArchivedContextsAreReadonly(): void
|
||||
public function testNonActiveContextsAreReadonly(): void
|
||||
{
|
||||
$this->assertTrue((new SchoolYearContext(5, '2026-2027', 'draft'))->isReadonly());
|
||||
$this->assertTrue((new SchoolYearContext(6, '2026-2027', 'closing'))->isReadonly());
|
||||
$this->assertTrue((new SchoolYearContext(2, '2023-2024', 'closed'))->isReadonly());
|
||||
$this->assertTrue((new SchoolYearContext(1, '2022-2023', 'archived'))->isReadonly());
|
||||
$this->assertFalse((new SchoolYearContext(5, '2026-2027', 'draft'))->isReadonly());
|
||||
$this->assertTrue((new SchoolYearContext(1, '2022-2023', 'archived'))->isHistorical());
|
||||
}
|
||||
|
||||
public function testArrayRepresentationIncludesReadonlyState(): void
|
||||
|
||||
Reference in New Issue
Block a user