PATH:
opt
/
cpanel
/
ea-wappspector
/
vendor
/
squizlabs
/
php_codesniffer
/
tests
/
Core
/
Tokenizers
/
PHP
<?php enum Foo { /* testPureEnumCase */ case SOME_CASE; } enum Boo: int { /* testBackingIntegerEnumCase */ case ONE = 1; } enum Hoo: string { /* testBackingStringEnumCase */ case ONE = 'one'; } enum ComplexEnum: int implements SomeInterface { use SomeTrait { traitMethod as enumMethod; } const SOME_CONSTANT = true; /* testEnumCaseInComplexEnum */ case ONE = 1; /* testEnumCaseIsCaseInsensitive */ CaSe TWO = 2; public function someMethod(): bool { switch (true) { /* testCaseWithSemicolonIsNotEnumCase */ case CONSTANT; } } /* testEnumCaseAfterSwitch */ case THREE = 3; public function someOtherMethod(): bool { switch (true): case false: endswitch; } /* testEnumCaseAfterSwitchWithEndSwitch */ case FOUR = 4; } switch (true) { /* testCaseWithConstantIsNotEnumCase */ case CONSTANT: /* testCaseWithConstantAndIdenticalIsNotEnumCase */ case CONSTANT === 1: /* testCaseWithAssigmentToConstantIsNotEnumCase */ case CONSTANT = 1: /* testIsNotEnumCaseIsCaseInsensitive */ cAsE CONSTANT: } switch ($x) { /* testCaseInSwitchWhenCreatingEnumInSwitch1 */ case 'a': { enum Foo {} break; } /* testCaseInSwitchWhenCreatingEnumInSwitch2 */ case 'b'; enum Bar {} break; } enum Foo: string { /* testKeywordAsEnumCaseNameShouldBeString1 */ case INTERFACE = 'interface'; /* testKeywordAsEnumCaseNameShouldBeString2 */ case TRAIT = 'trait'; /* testKeywordAsEnumCaseNameShouldBeString3 */ case ENUM = 'enum'; /* testKeywordAsEnumCaseNameShouldBeString4 */ case FUNCTION = 'function'; /* testKeywordAsEnumCaseNameShouldBeString5 */ case FALSE = 'false'; /* testKeywordAsEnumCaseNameShouldBeString6 */ case DEFAULT = 'default'; /* testKeywordAsEnumCaseNameShouldBeString7 */ case ARRAY = 'array'; /* testKeywordAsEnumCaseNameShouldBeString8 */ case EXIT = 'exit'; }
[-] BackfillExplicitOctalNotationTest.php
[edit]
[-] PHPOpenTagEOF2Test.inc
[edit]
[-] BackfillEnumTest.inc
[edit]
[-] PHPOpenTagEOF1Test.php
[edit]
[-] BackfillAsymmetricVisibilityTest.php
[edit]
[-] EnumCaseTest.php
[edit]
[-] StableCommentWhitespaceTest.inc
[edit]
[-] HeredocNowdocTest.inc
[edit]
[-] TypeIntersectionTest.php
[edit]
[-] DNFTypesParseError2Test.php
[edit]
[-] TypeIntersectionTest.inc
[edit]
[-] NamedFunctionCallArgumentsTest.inc
[edit]
[-] TypedConstantsTest.inc
[edit]
[-] UndoNamespacedNameSingleTokenTest.php
[edit]
[-] BackfillFnTokenParseErrorTest.inc
[edit]
[+]
..
[-] StableCommentWhitespaceWinTest.php
[edit]
[-] DNFTypesTest.inc
[edit]
[-] DNFTypesParseError1Test.inc
[edit]
[-] BitwiseOrTest.php
[edit]
[-] BackfillFnTokenParseErrorTest.php
[edit]
[-] DoubleQuotedStringTest.php
[edit]
[-] BackfillReadonlyTest.inc
[edit]
[-] PHPOpenTagEOF1Test.inc
[edit]
[-] PHPOpenTagEOF2Test.php
[edit]
[-] BackfillNumericSeparatorTest.inc
[edit]
[-] ArrayKeywordTest.inc
[edit]
[-] BackfillMatchTokenTest.php
[edit]
[-] DoubleArrowTest.inc
[edit]
[-] HeredocStringTest.inc
[edit]
[-] GotoLabelTest.inc
[edit]
[-] OtherContextSensitiveKeywordsTest.php
[edit]
[-] StableCommentWhitespaceTest.php
[edit]
[-] NullsafeObjectOperatorTest.php
[edit]
[-] DNFTypesParseError1Test.php
[edit]
[-] AttributesTest.php
[edit]
[-] ExitKeywordTest.inc
[edit]
[-] HeredocParseErrorTest.php
[edit]
[-] AnonClassParenthesisOwnerTest.php
[edit]
[-] NullableVsInlineThenTest.inc
[edit]
[-] ArrayKeywordTest.php
[edit]
[-] NullsafeObjectOperatorTest.inc
[edit]
[-] BackfillExplicitOctalNotationTest.inc
[edit]
[-] ResolveSimpleTokenTest.inc
[edit]
[-] DNFTypesParseError2Test.inc
[edit]
[-] BackfillEnumTest.php
[edit]
[-] YieldTest.inc
[edit]
[-] BackfillReadonlyTest.php
[edit]
[-] HeredocNowdocTest.php
[edit]
[-] ShortArrayTest.inc
[edit]
[-] DefaultKeywordTest.php
[edit]
[-] StableCommentWhitespaceWinTest.inc
[edit]
[-] BitwiseOrTest.inc
[edit]
[-] DNFTypesTest.php
[edit]
[-] DoubleArrowTest.php
[edit]
[-] EnumCaseTest.inc
[edit]
[-] TypedConstantsTest.php
[edit]
[-] BackfillNumericSeparatorTest.php
[edit]
[-] BackfillFnTokenTest.php
[edit]
[-] FinallyTest.inc
[edit]
[-] HeredocStringTest.php
[edit]
[-] ShortArrayTest.php
[edit]
[-] BackfillMatchTokenTest.inc
[edit]
[-] NullableVsInlineThenTest.php
[edit]
[-] DoubleQuotedStringTest.inc
[edit]
[-] GotoLabelTest.php
[edit]
[-] ExitKeywordTest.php
[edit]
[-] HeredocParseErrorTest.inc
[edit]
[-] ResolveSimpleTokenTest.php
[edit]
[-] UndoNamespacedNameSingleTokenTest.inc
[edit]
[-] OtherContextSensitiveKeywordsTest.inc
[edit]
[-] NamedFunctionCallArgumentsTest.php
[edit]
[-] AnonClassParenthesisOwnerTest.inc
[edit]
[-] PHPOpenTagEOF3Test.inc
[edit]
[-] BackfillFnTokenTest.inc
[edit]
[-] BackfillAsymmetricVisibilityTest.inc
[edit]
[-] AttributesTest.inc
[edit]
[-] ContextSensitiveKeywordsTest.inc
[edit]
[-] FinallyTest.php
[edit]
[-] PHPOpenTagEOF3Test.php
[edit]
[-] YieldTest.php
[edit]
[-] DefaultKeywordTest.inc
[edit]
[-] ContextSensitiveKeywordsTest.php
[edit]