Skip to content

Commit ec28ee6

Browse files
committed
PHP 8.4 | Squiz/ScopeKeywordSpacing: add tests with abstract properties
1 parent 92f35dd commit ec28ee6

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

src/Standards/Squiz/Tests/WhiteSpace/ScopeKeywordSpacingUnitTest.1.inc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,3 +202,8 @@ class AsymVisibility {
202202
protected(set) public $asymPublicProtected = 'hello';
203203
protected private(set) $asymProtectedPrivate = 'hello';
204204
}
205+
206+
abstract class AbstractProperties {
207+
abstract public ?MyType $spacing_correct {get;}
208+
protected abstract $spacing_incorrect { set; }
209+
}

src/Standards/Squiz/Tests/WhiteSpace/ScopeKeywordSpacingUnitTest.1.inc.fixed

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,3 +195,8 @@ class AsymVisibility {
195195
protected(set) public $asymPublicProtected = 'hello';
196196
protected private(set) $asymProtectedPrivate = 'hello';
197197
}
198+
199+
abstract class AbstractProperties {
200+
abstract public ?MyType $spacing_correct {get;}
201+
protected abstract $spacing_incorrect { set; }
202+
}

src/Standards/Squiz/Tests/WhiteSpace/ScopeKeywordSpacingUnitTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ public function getErrorList($testFile='')
7373
197 => 1,
7474
198 => 3,
7575
199 => 2,
76+
208 => 2,
7677
];
7778

7879
case 'ScopeKeywordSpacingUnitTest.3.inc':

0 commit comments

Comments
 (0)