From 9e0d8c1e800dcbb402536babd6628b68c5e0bfdc Mon Sep 17 00:00:00 2001 From: Mikhail Yohman Date: Mon, 16 Feb 2026 15:02:06 -0700 Subject: [PATCH 1/2] Fix pytest plugin for integration tests and empty YAML files (#744) --- infrahub_sdk/pytest_plugin/items/python_transform.py | 1 + infrahub_sdk/pytest_plugin/loader.py | 2 +- infrahub_sdk/pytest_plugin/models.py | 6 ++++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/infrahub_sdk/pytest_plugin/items/python_transform.py b/infrahub_sdk/pytest_plugin/items/python_transform.py index f77b1aa1..0ec42052 100644 --- a/infrahub_sdk/pytest_plugin/items/python_transform.py +++ b/infrahub_sdk/pytest_plugin/items/python_transform.py @@ -89,6 +89,7 @@ def runtest(self) -> None: class InfrahubPythonTransformIntegrationItem(InfrahubPythonTransformItem): def runtest(self) -> None: + self.instantiate_transform() input_data = self.session.infrahub_client.query_gql_query( # type: ignore[attr-defined] self.transform_instance.query, variables=self.test.spec.get_variables_data(), # type: ignore[union-attr] diff --git a/infrahub_sdk/pytest_plugin/loader.py b/infrahub_sdk/pytest_plugin/loader.py index 590a4ed7..5912a0c3 100644 --- a/infrahub_sdk/pytest_plugin/loader.py +++ b/infrahub_sdk/pytest_plugin/loader.py @@ -101,7 +101,7 @@ def collect_group(self, group: InfrahubTestGroup) -> Iterable[Item]: def collect(self) -> Iterable[Item]: raw = yaml.safe_load(self.path.open(encoding="utf-8")) - if "infrahub_tests" not in raw: + if not raw or "infrahub_tests" not in raw: return content = InfrahubTestFileV1(**raw) diff --git a/infrahub_sdk/pytest_plugin/models.py b/infrahub_sdk/pytest_plugin/models.py index 2bebfa77..13e81b90 100644 --- a/infrahub_sdk/pytest_plugin/models.py +++ b/infrahub_sdk/pytest_plugin/models.py @@ -31,7 +31,7 @@ class InfrahubInputOutputTest(InfrahubBaseTest): directory: Path | None = Field( None, description="Path to the directory where the input and output files are located" ) - input: Path = Field( + input: Path | None = Field( Path("input.json"), description="Path to the file with the input data for the test, can be a relative path from the config file or from the directory.", ) @@ -68,7 +68,7 @@ def update_paths(self, base_dir: Path) -> None: else: self.directory = base_dir - if not self.input or not self.input.is_file(): + if self.input is not None and not self.input.is_file(): search_input: Path | str = self.input or "input.*" results = list(self.directory.rglob(str(search_input))) @@ -99,6 +99,8 @@ def get_output_data(self) -> Any: class InfrahubIntegrationTest(InfrahubInputOutputTest): + # Integration tests get input from live GraphQL queries, not from input files + input: Path | None = Field(None) variables: Path | dict[str, Any] = Field( Path("variables.json"), description="Variables and corresponding values to pass to the GraphQL query" ) From 5a8c09109c02fff72b39cb75f7fd5ea8fb9f0049 Mon Sep 17 00:00:00 2001 From: Fatih Acar Date: Wed, 18 Feb 2026 16:08:32 +0100 Subject: [PATCH 2/2] fix(ci): remove archived repos from release process Signed-off-by: Fatih Acar --- .github/workflows/repository-dispatch.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/repository-dispatch.yml b/.github/workflows/repository-dispatch.yml index 261429df..7dce497f 100644 --- a/.github/workflows/repository-dispatch.yml +++ b/.github/workflows/repository-dispatch.yml @@ -35,9 +35,8 @@ jobs: matrix: # Either a literal path, or the name of a secret... repo: - - "opsmill/infrahub-demo-dc-fabric" + - "opsmill/infrahub-bundle-dc" - "INFRAHUB_CUSTOMER1_REPOSITORY" - - "INFRAHUB_CUSTOMER2_REPOSITORY" - "INFRAHUB_CUSTOMER3_REPOSITORY" steps: