Skip to content

Commit

Permalink
Squiz/FunctionDeclarationArgumentSpacing: add parse error/live coding…
Browse files Browse the repository at this point in the history
… tests
  • Loading branch information
jrfnl committed Jan 23, 2025
1 parent 7463c78 commit d62f08d
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?php

// Intentional parse error/live coding.
// Ensuring that the sniff ignores unfinished function declarations (missing open parenthesis).
// This must be the only test in this file.
function
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?php

// Intentional parse error/live coding.
// Ensuring that the sniff ignores unfinished function declarations (missing close parenthesis).
// This must be the only test in this file.
$closure = function (string $paramA, int &...$paramB,
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?php

// Intentional parse error/live coding.
// Ensuring that the sniff ignores unfinished function declarations (missing open parenthesis for import use).
// This must be the only test in this file.
$closure = function (string $param) use
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?php

// Intentional parse error/live coding.
// Ensuring that the sniff ignores unfinished function declarations (missing close parenthesis for import use).
// This must be the only test in this file.
$closure = function (string $param) use ($var
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?php

// Intentional parse error/live coding.
// Ensuring that the sniff ignores unfinished function declarations (missing close parenthesis).
// This must be the only test in this file.
$arrow = static fn (string $paramA

0 comments on commit d62f08d

Please sign in to comment.