Skip to content

Commit 969ab78

Browse files
authored
Merge pull request #22048 from github/jketema/kotlin1-pytest
Kotlin: Update tests to use new `kotlin_2_3_20` fixture
2 parents b67644c + 9b2e607 commit 969ab78

6 files changed

Lines changed: 7 additions & 21 deletions

File tree

  • java/ql/integration-tests/kotlin/all-platforms

java/ql/integration-tests/kotlin/all-platforms/enhanced-nullability/test.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
import pathlib
2-
import pytest
32

43

5-
@pytest.mark.kotlin1
6-
def test(codeql, java_full):
4+
def test(codeql, java_full, kotlinc_2_3_20):
75
java_srcs = " ".join([str(s) for s in pathlib.Path().glob("*.java")])
86
codeql.database.create(
97
command=[
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
import commands
2-
import pytest
32

43

5-
@pytest.mark.kotlin1
6-
def test(codeql, java_full):
4+
def test(codeql, java_full, kotlinc_2_3_20):
75
commands.run("kotlinc -language-version 1.9 test.kt -d lib")
86
codeql.database.create(command="kotlinc -language-version 1.9 user.kt -cp lib")
Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,2 @@
1-
import pytest
2-
3-
4-
@pytest.mark.kotlin1
5-
def test(codeql, java_full):
6-
codeql.database.create(command="kotlinc -J-Xmx2G -language-version 1.9 SomeClass.kt")
1+
def test(codeql, java_full, kotlinc_2_3_20):
2+
codeql.database.create(command=f"kotlinc -J-Xmx2G -language-version 1.9 SomeClass.kt")
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
import commands
2-
import pytest
32

43

5-
@pytest.mark.kotlin1
6-
def test(codeql, java_full):
4+
def test(codeql, java_full, kotlinc_2_3_20):
75
commands.run("kotlinc -language-version 1.9 A.kt")
86
codeql.database.create(command="kotlinc -cp . -language-version 1.9 B.kt C.kt")
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
import commands
2-
import pytest
32

43

5-
@pytest.mark.kotlin1
6-
def test(codeql, java_full):
4+
def test(codeql, java_full, kotlinc_2_3_20):
75
commands.run(["javac", "Test.java", "-d", "bin"])
86
codeql.database.create(command="kotlinc -language-version 1.9 user.kt -cp bin")

java/ql/integration-tests/kotlin/all-platforms/kotlin_java_lowering_wildcards/test.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
import commands
2-
import pytest
32

43

5-
@pytest.mark.kotlin1
6-
def test(codeql, java_full):
4+
def test(codeql, java_full, kotlinc_2_3_20):
75
# Compile the JavaDefns2 copy outside tracing, to make sure the Kotlin view of it matches the Java view seen by the traced javac compilation of JavaDefns.java below.
86
commands.run(["javac", "JavaDefns2.java"])
97
codeql.database.create(

0 commit comments

Comments
 (0)