Add CallLike test for NullsafeMethodCall

This commit is contained in:
Nikita Popov 2021-11-14 17:44:47 +01:00
parent 4122ff3a91
commit 63f8699143

View File

@ -29,8 +29,10 @@ class CallableLikeTest extends \PHPUnit\Framework\TestCase {
[new StaticCall(new Name('Test'), 'test', $normalArgs), false],
[new StaticCall(new Name('Test'), 'test', $callableArgs), true],
[new New_(new Name('Test'), $normalArgs), false],
[new NullsafeMethodCall(new Variable('this'), 'test', $normalArgs), false],
// This is not legal code, but accepted by the parser.
[new New_(new Name('Test'), $callableArgs), true],
[new NullsafeMethodCall(new Variable('this'), 'test', $callableArgs), true],
];
}
}