mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
Rust: accept last integration test changes
Also make `--learn` work with the nested qltest tests.
This commit is contained in:
@@ -1 +0,0 @@
|
||||
| test.rs:4:1:7:1 | foo |
|
||||
@@ -0,0 +1 @@
|
||||
| test.rs:4:1:7:1 | fn foo |
|
||||
@@ -1 +0,0 @@
|
||||
| test.rs:1:1:1:11 | foo |
|
||||
@@ -0,0 +1 @@
|
||||
| test.rs:1:1:1:11 | fn foo |
|
||||
@@ -1,2 +0,0 @@
|
||||
| main.rs:1:1:1:12 | main |
|
||||
| test.rs:1:1:1:11 | foo |
|
||||
@@ -0,0 +1,2 @@
|
||||
| main.rs:1:1:1:12 | fn main |
|
||||
| test.rs:1:1:1:11 | fn foo |
|
||||
@@ -6,16 +6,17 @@ import pytest
|
||||
# (which skips `qltest.{sh,cmd}`)
|
||||
|
||||
@pytest.fixture(autouse=True)
|
||||
def default_options(codeql, pytestconfig):
|
||||
def default_options(codeql):
|
||||
codeql.flags.update(
|
||||
threads = 1,
|
||||
show_extractor_output = True,
|
||||
check_databases = False,
|
||||
learn = pytestconfig.getoption("learn"),
|
||||
learn = True,
|
||||
)
|
||||
|
||||
@pytest.mark.parametrize("dir", ["lib", "main", "dependencies"])
|
||||
def test(codeql, rust, dir):
|
||||
def test(codeql, rust, expected_files, dir):
|
||||
expected_files.add(f"{dir}/functions.expected", expected=".nested.expected")
|
||||
codeql.test.run(dir)
|
||||
|
||||
def test_failing_cargo_check(codeql, rust):
|
||||
Reference in New Issue
Block a user