Skip to content

Commit ea696b4

Browse files
committed
Fix tests to match new parse error format
1 parent 739a79a commit ea696b4

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+48
-48
lines changed

Zend/tests/attributes/018_variable_attribute_name.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ class A {}
88

99
?>
1010
--EXPECTF--
11-
Parse error: syntax error, unexpected '$x' (T_VARIABLE), expecting identifier (T_STRING) or static (T_STATIC) or namespace (T_NAMESPACE) or \\ (T_NS_SEPARATOR) in %s on line %d
11+
Parse error: syntax error, unexpected variable '$x', expecting identifier or 'static' or 'namespace' or '\' in %s on line %d

Zend/tests/bug43343.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ $foo = 'bar';
88
var_dump(new namespace::$foo);
99
?>
1010
--EXPECTF--
11-
Parse error: %s error%sexpecting%sT_NS_SEPARATOR%sin %sbug43343.php on line 5
11+
Parse error: %s error%sexpecting%s'\'%sin %sbug43343.php on line 5

Zend/tests/bug75252.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,5 @@ try {
2424

2525
?>
2626
--EXPECT--
27-
string(41) "syntax error, unexpected 'FOO' (T_STRING)"
28-
string(41) "syntax error, unexpected 'FOO' (T_STRING)"
27+
string(41) "syntax error, unexpected identifier 'FOO'"
28+
string(41) "syntax error, unexpected identifier 'FOO'"

Zend/tests/bug77993.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ Bug #77993 (Wrong parse error for invalid hex literal on Windows)
44
<?php
55
0xg10;
66
--EXPECTF--
7-
Parse error: syntax error, unexpected 'xg10' (T_STRING) in %s on line %d
7+
Parse error: syntax error, unexpected identifier 'xg10' in %s on line %d

Zend/tests/bug78454_1.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ Invalid consecutive numeric separators after hex literal
44
<?php
55
0x0__F;
66
--EXPECTF--
7-
Parse error: syntax error, unexpected '__F' (T_STRING) in %s on line %d
7+
Parse error: syntax error, unexpected identifier '__F' in %s on line %d

Zend/tests/bug78454_2.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ Invalid consecutive numeric separators after binary literal
44
<?php
55
0b0__1
66
--EXPECTF--
7-
Parse error: syntax error, unexpected '__1' (T_STRING) in %s on line %d
7+
Parse error: syntax error, unexpected identifier '__1' in %s on line %d

Zend/tests/ctor_promotion_additional_modifiers.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@ class Test {
99

1010
?>
1111
--EXPECTF--
12-
Parse error: syntax error, unexpected 'static' (T_STATIC), expecting variable (T_VARIABLE) in %s on line %d
12+
Parse error: syntax error, unexpected token 'static', expecting variable in %s on line %d

Zend/tests/flexible-heredoc-error7.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ Note: the closing ?> has been deliberately elided.
88
echo <<<END
99

1010
--EXPECTF--
11-
Parse error: syntax error, unexpected end of file, expecting variable (T_VARIABLE) or heredoc end (T_END_HEREDOC) or ${ (T_DOLLAR_OPEN_CURLY_BRACES) or {$ (T_CURLY_OPEN) in %s on line %d
11+
Parse error: syntax error, unexpected end of file, expecting variable or heredoc end or '${' or '{$' in %s on line %d

Zend/tests/flexible-nowdoc-error7.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ Note: the closing ?> has been deliberately elided.
88
echo <<<'END'
99
1010
--EXPECTF--
11-
Parse error: syntax error, unexpected end of file, expecting variable (T_VARIABLE) or heredoc end (T_END_HEREDOC) or ${ (T_DOLLAR_OPEN_CURLY_BRACES) or {$ (T_CURLY_OPEN) in %s on line %d
11+
Parse error: syntax error, unexpected end of file, expecting variable or heredoc end or '${' or '{$' in %s on line %d

Zend/tests/flexible-nowdoc-error8.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ eval('<<<\'end\'
88

99
?>
1010
--EXPECTF--
11-
Parse error: syntax error, unexpected end of file, expecting variable (T_VARIABLE) or heredoc end (T_END_HEREDOC) or ${ (T_DOLLAR_OPEN_CURLY_BRACES) or {$ (T_CURLY_OPEN) in %s on line %d
11+
Parse error: syntax error, unexpected end of file, expecting variable or heredoc end or '${' or '{$' in %s on line %d

0 commit comments

Comments
 (0)