Merge pull request #11019 from igfoo/igfoo/win_integ

Kotlin: Get some integration tests running on Windows
This commit is contained in:
Ian Lynagh
2022-10-28 16:12:15 +01:00
committed by GitHub
119 changed files with 23 additions and 10 deletions

View File

@@ -2,9 +2,9 @@
from create_database_utils import *
runSuccessfully(["kotlinc", "KotlinDefault.kt"])
runSuccessfully([get_cmd("kotlinc"), "KotlinDefault.kt"])
os.environ['CODEQL_EXTRACTOR_JAVA_AGENT_DISABLE_KOTLIN'] = 'true'
runSuccessfully(["kotlinc", "KotlinDisabled.kt"])
runSuccessfully([get_cmd("kotlinc"), "KotlinDisabled.kt"])
del(os.environ['CODEQL_EXTRACTOR_JAVA_AGENT_DISABLE_KOTLIN'])
os.environ['CODEQL_EXTRACTOR_JAVA_AGENT_ENABLE_KOTLIN'] = 'true'
runSuccessfully(["kotlinc", "KotlinEnabled.kt"])
runSuccessfully([get_cmd("kotlinc"), "KotlinEnabled.kt"])

View File

@@ -1,5 +1,5 @@
from create_database_utils import *
os.mkdir('lib')
runSuccessfully(["kotlinc", "test.kt", "-d", "lib"])
runSuccessfully([get_cmd("kotlinc"), "test.kt", "-d", "lib"])
run_codeql_database_create(["kotlinc user.kt -cp lib"], lang="java")

View File

@@ -3,6 +3,8 @@
import os
import subprocess
from create_database_utils import *
os.environ['CODEQL_KOTLIN_INTERNAL_EXCEPTION_WHILE_EXTRACTING_FILE'] = 'B.kt'
subprocess.check_call(['kotlinc', 'A.kt', 'B.kt', 'C.kt', ])
subprocess.check_call([get_cmd('kotlinc'), 'A.kt', 'B.kt', 'C.kt', ])

View File

@@ -1,4 +1,4 @@
from create_database_utils import *
run_codeql_database_create(["gradle build --no-daemon --no-build-cache"], lang="java")
runSuccessfully(["gradle", "clean"])
runSuccessfully([get_cmd("gradle"), "clean"])

View File

@@ -1,4 +1,4 @@
from create_database_utils import *
run_codeql_database_create(["gradle build --no-daemon --no-build-cache"], lang="java")
runSuccessfully(["gradle", "clean"])
runSuccessfully([get_cmd("gradle"), "clean"])

View File

@@ -5,7 +5,7 @@ import glob
# will certainly reference the jar, not the source or class file.
os.mkdir('build')
runSuccessfully(["kotlinc"] + glob.glob("libsrc/*.kt") + ["-d", "build"])
runSuccessfully([get_cmd("kotlinc")] + glob.glob("libsrc/*.kt") + ["-d", "build"])
runSuccessfully(["jar", "cf", "extlib.jar", "-C", "build", "abcdefghij", "-C", "build", "META-INF"])
run_codeql_database_create(["kotlinc user.kt -cp extlib.jar"], lang="java")

View File

@@ -2,4 +2,4 @@ from create_database_utils import *
run_codeql_database_create(
["gradle build --no-daemon --no-build-cache --rerun-tasks"], lang="java")
runSuccessfully(["gradle", "clean"])
runSuccessfully([get_cmd("gradle"), "clean"])

View File

@@ -2,5 +2,5 @@
from create_database_utils import *
runSuccessfully(["kotlinc", "FileA.kt", "FileB.kt"])
runSuccessfully([get_cmd("kotlinc"), "FileA.kt", "FileB.kt"])

Some files were not shown because too many files have changed in this diff Show More