Skip to content

Commit

Permalink
Update existing tests/snapshots with syntax errors
Browse files Browse the repository at this point in the history
  • Loading branch information
dhruvmanila committed Jun 18, 2024
1 parent dee6720 commit 80326bd
Show file tree
Hide file tree
Showing 12 changed files with 308 additions and 24 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,7 @@ def bah(ham, spam, ):

image[:,:,]

lambda x, :
lambda x, : x

# ==> unpack.py <==
def function(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@ COM81.py:511:10: COM819 [*] Trailing comma prohibited
511 | image[:,:,]
| ^ COM819
512 |
513 | lambda x, :
513 | lambda x, : x
|
= help: Remove trailing comma

Expand All @@ -612,14 +612,14 @@ COM81.py:511:10: COM819 [*] Trailing comma prohibited
511 |-image[:,:,]
511 |+image[:,:]
512 512 |
513 513 | lambda x, :
513 513 | lambda x, : x
514 514 |

COM81.py:513:9: COM819 [*] Trailing comma prohibited
|
511 | image[:,:,]
512 |
513 | lambda x, :
513 | lambda x, : x
| ^ COM819
514 |
515 | # ==> unpack.py <==
Expand All @@ -630,8 +630,8 @@ COM81.py:513:9: COM819 [*] Trailing comma prohibited
510 510 |
511 511 | image[:,:,]
512 512 |
513 |-lambda x, :
513 |+lambda x :
513 |-lambda x, : x
513 |+lambda x : x
514 514 |
515 515 | # ==> unpack.py <==
516 516 | def function(
Expand Down Expand Up @@ -798,6 +798,14 @@ COM81.py:565:13: COM812 [*] Trailing comma missing
567 567 |
568 568 | (

COM81.py:569:5: E999 SyntaxError: Starred expression cannot be used here
|
568 | (
569 | *args
| ^ E999
570 | )
|

COM81.py:573:10: COM812 [*] Trailing comma missing
|
572 | {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,42 @@ E11.py:6:1: E111 Indentation is not a multiple of 4
8 | if False:
|

E11.py:9:1: E999 SyntaxError: Expected an indented block after `if` statement
|
7 | #: E112
8 | if False:
9 | print()
| ^ E999
10 | #: E113
11 | print()
|

E11.py:12:1: E999 SyntaxError: Unexpected indentation
|
10 | #: E113
11 | print()
12 | print()
| ^ E999
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
|

E11.py:14:1: E999 SyntaxError: Expected a statement
|
12 | print()
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
| ^ E999
15 | # 'httpd/unix-directory'
16 | create_date = False
|

E11.py:45:1: E999 SyntaxError: Expected an indented block after `if` statement
|
43 | #: E112
44 | if False: #
45 | print()
| ^ E999
46 | #:
47 | if False:
|
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,36 @@ E11.py:9:1: E112 Expected an indented block
11 | print()
|

E11.py:9:1: E999 SyntaxError: Expected an indented block after `if` statement
|
7 | #: E112
8 | if False:
9 | print()
| ^ E999
10 | #: E113
11 | print()
|

E11.py:12:1: E999 SyntaxError: Unexpected indentation
|
10 | #: E113
11 | print()
12 | print()
| ^ E999
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
|

E11.py:14:1: E999 SyntaxError: Expected a statement
|
12 | print()
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
| ^ E999
15 | # 'httpd/unix-directory'
16 | create_date = False
|

E11.py:45:1: E112 Expected an indented block
|
43 | #: E112
Expand All @@ -21,4 +51,12 @@ E11.py:45:1: E112 Expected an indented block
47 | if False:
|


E11.py:45:1: E999 SyntaxError: Expected an indented block after `if` statement
|
43 | #: E112
44 | if False: #
45 | print()
| ^ E999
46 | #:
47 | if False:
|
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
---
source: crates/ruff_linter/src/rules/pycodestyle/mod.rs
---
E11.py:9:1: E999 SyntaxError: Expected an indented block after `if` statement
|
7 | #: E112
8 | if False:
9 | print()
| ^ E999
10 | #: E113
11 | print()
|

E11.py:12:1: E113 Unexpected indentation
|
10 | #: E113
Expand All @@ -11,4 +21,32 @@ E11.py:12:1: E113 Unexpected indentation
14 | mimetype = 'application/x-directory'
|

E11.py:12:1: E999 SyntaxError: Unexpected indentation
|
10 | #: E113
11 | print()
12 | print()
| ^ E999
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
|

E11.py:14:1: E999 SyntaxError: Expected a statement
|
12 | print()
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
| ^ E999
15 | # 'httpd/unix-directory'
16 | create_date = False
|

E11.py:45:1: E999 SyntaxError: Expected an indented block after `if` statement
|
43 | #: E112
44 | if False: #
45 | print()
| ^ E999
46 | #:
47 | if False:
|
Original file line number Diff line number Diff line change
@@ -1,6 +1,36 @@
---
source: crates/ruff_linter/src/rules/pycodestyle/mod.rs
---
E11.py:9:1: E999 SyntaxError: Expected an indented block after `if` statement
|
7 | #: E112
8 | if False:
9 | print()
| ^ E999
10 | #: E113
11 | print()
|

E11.py:12:1: E999 SyntaxError: Unexpected indentation
|
10 | #: E113
11 | print()
12 | print()
| ^ E999
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
|

E11.py:14:1: E999 SyntaxError: Expected a statement
|
12 | print()
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
| ^ E999
15 | # 'httpd/unix-directory'
16 | create_date = False
|

E11.py:15:1: E114 Indentation is not a multiple of 4 (comment)
|
13 | #: E114 E116
Expand All @@ -11,4 +41,12 @@ E11.py:15:1: E114 Indentation is not a multiple of 4 (comment)
17 | #: E116 E116 E116
|


E11.py:45:1: E999 SyntaxError: Expected an indented block after `if` statement
|
43 | #: E112
44 | if False: #
45 | print()
| ^ E999
46 | #:
47 | if False:
|
Original file line number Diff line number Diff line change
@@ -1,6 +1,36 @@
---
source: crates/ruff_linter/src/rules/pycodestyle/mod.rs
---
E11.py:9:1: E999 SyntaxError: Expected an indented block after `if` statement
|
7 | #: E112
8 | if False:
9 | print()
| ^ E999
10 | #: E113
11 | print()
|

E11.py:12:1: E999 SyntaxError: Unexpected indentation
|
10 | #: E113
11 | print()
12 | print()
| ^ E999
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
|

E11.py:14:1: E999 SyntaxError: Expected a statement
|
12 | print()
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
| ^ E999
15 | # 'httpd/unix-directory'
16 | create_date = False
|

E11.py:30:1: E115 Expected an indented block (comment)
|
28 | def start(self):
Expand Down Expand Up @@ -61,4 +91,12 @@ E11.py:35:1: E115 Expected an indented block (comment)
37 | #: E117
|


E11.py:45:1: E999 SyntaxError: Expected an indented block after `if` statement
|
43 | #: E112
44 | if False: #
45 | print()
| ^ E999
46 | #:
47 | if False:
|
Original file line number Diff line number Diff line change
@@ -1,6 +1,36 @@
---
source: crates/ruff_linter/src/rules/pycodestyle/mod.rs
---
E11.py:9:1: E999 SyntaxError: Expected an indented block after `if` statement
|
7 | #: E112
8 | if False:
9 | print()
| ^ E999
10 | #: E113
11 | print()
|

E11.py:12:1: E999 SyntaxError: Unexpected indentation
|
10 | #: E113
11 | print()
12 | print()
| ^ E999
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
|

E11.py:14:1: E999 SyntaxError: Expected a statement
|
12 | print()
13 | #: E114 E116
14 | mimetype = 'application/x-directory'
| ^ E999
15 | # 'httpd/unix-directory'
16 | create_date = False
|

E11.py:15:1: E116 Unexpected indentation (comment)
|
13 | #: E114 E116
Expand Down Expand Up @@ -41,4 +71,12 @@ E11.py:26:1: E116 Unexpected indentation (comment)
28 | def start(self):
|


E11.py:45:1: E999 SyntaxError: Expected an indented block after `if` statement
|
43 | #: E112
44 | if False: #
45 | print()
| ^ E999
46 | #:
47 | if False:
|
Loading

0 comments on commit 80326bd

Please sign in to comment.