Add test for expected filenames

This commit is contained in:
Chris Smowton
2021-11-16 17:49:08 +00:00
committed by Ian Lynagh
parent 5ec546bcb0
commit 87b04bc22b
4 changed files with 29 additions and 0 deletions

View File

@@ -0,0 +1,3 @@
package main
class DefinedOtherFile<T> { }

View File

@@ -0,0 +1,7 @@
| otherfile.kt:3:1:3:29 | other | Object | Object.class | 0 |
| test.kt:7:3:7:11 | b | String | String.class | 0 |
| test.kt:8:3:8:24 | c | List<String> | List.class | 0 |
| test.kt:9:3:9:28 | d | List<? extends String> | List.class | 0 |
| test.kt:10:3:10:24 | e | DefinedHere<String> | test.kt | 14 |
| test.kt:11:3:11:29 | f | DefinedOtherFile<String> | otherfile.kt | 3 |
| test.kt:14:1:14:24 | other | Object | Object.class | 0 |

View File

@@ -0,0 +1,14 @@
package main
import kotlin.collections.MutableList
fun test(
a: Int,
b: String,
c: MutableList<String>,
d: MutableList<out String>,
e: DefinedHere<String>,
f: DefinedOtherFile<String>
) { }
class DefinedHere<T> { }

View File

@@ -0,0 +1,5 @@
import java
from Parameter p
where p.fromSource()
select p, p.getType().toString(), p.getType().getFile().getBaseName(), p.getType().getLocation().getStartLine()