Skip to content

Commit 6bf8889

Browse files
committed
Add another path linker test
1 parent 7ab474d commit 6bf8889

2 files changed

Lines changed: 29 additions & 0 deletions

File tree

src/test/kotlin/insyncwithfoo/ryecharm/others/consolefilters/RuffAndTYPathLinkerTest.kt

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,4 +192,32 @@ internal class RuffAndTYPathLinkerTest : ConsoleFilterTest() {
192192
)
193193
}
194194

195+
@Test
196+
fun `test leading space in file name`() = fileBasedTest(" leading_space.py") {
197+
filterTest(
198+
before = """
199+
|B006 Do not use mutable data structures for argument defaults
200+
| --> leading_space.py:1:11
201+
| |
202+
|1 | def f(a = []): ...
203+
| | ^^
204+
| |
205+
|help: Replace with `None`; initialize within function
206+
|
207+
|Found 1 error.
208+
""".trimMargin(),
209+
after = """
210+
|B006 Do not use mutable data structures for argument defaults
211+
| --> [ leading_space.py:1:11 -> leading_space.py]
212+
| |
213+
|1 | def f(a = []): ...
214+
| | ^^
215+
| |
216+
|help: Replace with `None`; initialize within function
217+
|
218+
|Found 1 error.
219+
""".trimMargin()
220+
)
221+
}
222+
195223
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
def f(a = []): ...

0 commit comments

Comments
 (0)