Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/harness.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ permissions: {}

jobs:
harness:
uses: Pollora/harness/.github/workflows/php-package.yml@v0.1.20
uses: Pollora/harness/.github/workflows/php-package.yml@v0.1.22
permissions:
contents: read
6 changes: 6 additions & 0 deletions .harness.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
"downstream": [
"framework"
],
"allow_rules": [
{
"rule": "ARCH-08",
"reason": "the attribute classes are published; final/readonly waits for the next major version"
}
],
"ratchet": {
"phpstan_level": 5,
"phpstan_baseline": 0,
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- The harness's ARCH-08 rule (attribute classes are final, with `readonly` public properties) is skipped in `tests/Arch.php`, for this repository only: the classes are published and may be extended, so making them `final` and `readonly` is a change of contract, planned for the next major version. Every other architecture rule stays active
- The harness's ARCH-08 rule (attribute classes are final, with `readonly` public properties) is exempted through `allow_rules` in `.harness.json`, for this repository only: the classes are published and may be extended, so making them `final` and `readonly` is a change of contract, planned for the next major version. Every other architecture rule stays active

## [0.1.1] - 2026-10-15

Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"laravel/pint": "^1.22.1",
"pestphp/pest": "^3.8.2",
"phpstan/phpstan": "^2.1.16",
"pollora/harness": "^0.1.20",
"pollora/harness": "^0.1.22",
"szepeviktor/phpstan-wordpress": "^2.0"
},
"autoload": {
Expand Down
16 changes: 0 additions & 16 deletions tests/Arch.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,4 @@
* `vendor/bin/pollora-qa rules`.
*/

/*
* ARCH-08 is left out on purpose, for this repository only.
*
* The attribute classes are published (since v0.1.0) and extended or mutated
* by the packages built on them: making them `final` and their public
* properties `readonly` would change the public contract, so it waits for a
* major version. Only ARCH-08 is skipped; every other rule below stays active.
* Remove this block, and the CHANGELOG entry that goes with it, when the
* attributes are made final and readonly in the next major release.
*/
beforeEach(function (): void {
if (str_contains($this->name(), 'ARCH_08')) {
$this->markTestSkipped('ARCH-08 waits for the next major version: final/readonly would change the published contract.');
}
});

Architecture::for(dirname(__DIR__))->register();
Loading