feat: CI/CD pipeline setup complete - Ansible playbooks updated, secrets configured, workflow ready
This commit is contained in:
38
tests/Unit/Framework/Attributes/StaticPageTest.php
Normal file
38
tests/Unit/Framework/Attributes/StaticPageTest.php
Normal file
@@ -0,0 +1,38 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use App\Framework\Attributes\StaticPage;
|
||||
|
||||
describe('StaticPage', function () {
|
||||
it('constructs with default values', function () {
|
||||
$staticPage = new StaticPage();
|
||||
|
||||
expect($staticPage->outputPath)->toBeNull();
|
||||
expect($staticPage->prerender)->toBeTrue();
|
||||
});
|
||||
|
||||
it('constructs with custom output path', function () {
|
||||
$staticPage = new StaticPage(outputPath: 'custom/path/index.html');
|
||||
|
||||
expect($staticPage->outputPath)->toBe('custom/path/index.html');
|
||||
expect($staticPage->prerender)->toBeTrue();
|
||||
});
|
||||
|
||||
it('constructs with prerender disabled', function () {
|
||||
$staticPage = new StaticPage(prerender: false);
|
||||
|
||||
expect($staticPage->outputPath)->toBeNull();
|
||||
expect($staticPage->prerender)->toBeFalse();
|
||||
});
|
||||
|
||||
it('constructs with all parameters', function () {
|
||||
$staticPage = new StaticPage(
|
||||
outputPath: 'static/pages/about.html',
|
||||
prerender: false
|
||||
);
|
||||
|
||||
expect($staticPage->outputPath)->toBe('static/pages/about.html');
|
||||
expect($staticPage->prerender)->toBeFalse();
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user