From 89071ed8e0461f9579788b17f196710e745249f5 Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Tue, 27 Jan 2026 01:26:14 +0100 Subject: [PATCH 1/3] clickable: Skip test that expects /tmp to never be symlink Fails on Darwin. --- pkgs/by-name/cl/clickable/package.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/pkgs/by-name/cl/clickable/package.nix b/pkgs/by-name/cl/clickable/package.nix index d0659f21c84d..9b8b9f6a837d 100644 --- a/pkgs/by-name/cl/clickable/package.nix +++ b/pkgs/by-name/cl/clickable/package.nix @@ -21,6 +21,8 @@ python3Packages.buildPythonApplication rec { hash = "sha256-W6NPZ5uP7wGjgyA+Nv2vpmshKWny2CCSrn/Gaoi7Pr4="; }; + __structuredAttrs = true; + build-system = [ python3Packages.setuptools ]; dependencies = with python3Packages; [ @@ -40,14 +42,18 @@ python3Packages.buildPythonApplication rec { ]; disabledTests = - # Tests require running docker daemon [ + # Require running docker daemon "test_cpp_plugin" "test_godot_plugin" "test_html" "test_python" "test_qml_only" "test_rust" + + # Expects /tmp to exist and not be a symlink + # https://gitlab.com/clickable/clickable/-/issues/479 + "TestReviewCommand and test_run and not test_run_with_path_arg" ] # Tests do not work on non-amd64 platforms ++ lib.optionals (!stdenv.hostPlatform.isx86_64) [ From 6a914e21e333a9fd1e60a4b1de0da7c513b9b54c Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Tue, 27 Jan 2026 01:51:13 +0100 Subject: [PATCH 2/3] clickable: Use class names in disabledTests `__structuredAttrs = true` now lets us build sub-expressions in disabledTests (which was necessary for skipping only one test that uses /tmp). We can make the test skipping more explicit now by including the class name, and excluding test functions that reuse the same name. In the case of the TestTemplates tests, we were disabling all of them, so just disable the class in general. test_init_cmake_project_* are covered by test_init_cmake_project being disabled. I was unaware that disabledTests only looks for substrings, not complete matches. --- pkgs/by-name/cl/clickable/package.nix | 48 +++++++++++---------------- 1 file changed, 19 insertions(+), 29 deletions(-) diff --git a/pkgs/by-name/cl/clickable/package.nix b/pkgs/by-name/cl/clickable/package.nix index 9b8b9f6a837d..012cbfc3fd31 100644 --- a/pkgs/by-name/cl/clickable/package.nix +++ b/pkgs/by-name/cl/clickable/package.nix @@ -41,37 +41,27 @@ python3Packages.buildPythonApplication rec { which ]; - disabledTests = - [ - # Require running docker daemon - "test_cpp_plugin" - "test_godot_plugin" - "test_html" - "test_python" - "test_qml_only" - "test_rust" + disabledTests = [ + # Requires running docker daemon + "TestTemplates" - # Expects /tmp to exist and not be a symlink - # https://gitlab.com/clickable/clickable/-/issues/479 - "TestReviewCommand and test_run and not test_run_with_path_arg" - ] - # Tests do not work on non-amd64 platforms - ++ lib.optionals (!stdenv.hostPlatform.isx86_64) [ - # hardcode amd64 - "test_arch" - "test_restricted_arch" + # Expects /tmp to exist and not be a symlink + # https://gitlab.com/clickable/clickable/-/issues/479 + "TestReviewCommand and test_run and not test_run_with_path_arg" + ] + ++ lib.optionals (!stdenv.hostPlatform.isx86_64) [ + # hardcode amd64 + "TestArchitectures and test_arch and not test_arch_agnostic" + "TestArchitectures and test_restricted_arch and not test_restricted_arch_env" - # no -ide images on arm64 - # https://gitlab.com/clickable/clickable/-/issues/478 - "test_command_overrided" - "test_init_cmake_project" - "test_init_cmake_project_exe_as_var" - "test_init_cmake_project_no_exe" - "test_init_cmake_project_no_to_prompt" - "test_initialize_qtcreator_conf" - "test_project_pre_configured" - "test_recurse_replace" - ]; + # no -ide images on non-x86_64 + # https://gitlab.com/clickable/clickable/-/issues/478 + "TestIdeQtCreatorCommand and test_command_overrided" + "TestIdeQtCreatorCommand and test_init_cmake_project" + "TestIdeQtCreatorCommand and test_initialize_qtcreator_conf" + "TestIdeQtCreatorCommand and test_project_pre_configured" + "TestIdeQtCreatorCommand and test_recurse_replace" + ]; passthru.updateScript = gitUpdater { rev-prefix = "v"; }; From f95c0e80aa79e2e352159662d2a44f6f3c1d7f16 Mon Sep 17 00:00:00 2001 From: OPNA2608 Date: Tue, 27 Jan 2026 22:52:15 +0100 Subject: [PATCH 3/3] clickable: Fix too many TestArchitectures tests getting disabled pytest only has prefix or infix matching. This sucks :( --- pkgs/by-name/cl/clickable/package.nix | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/pkgs/by-name/cl/clickable/package.nix b/pkgs/by-name/cl/clickable/package.nix index 012cbfc3fd31..aaa87abf5c83 100644 --- a/pkgs/by-name/cl/clickable/package.nix +++ b/pkgs/by-name/cl/clickable/package.nix @@ -50,9 +50,20 @@ python3Packages.buildPythonApplication rec { "TestReviewCommand and test_run and not test_run_with_path_arg" ] ++ lib.optionals (!stdenv.hostPlatform.isx86_64) [ - # hardcode amd64 - "TestArchitectures and test_arch and not test_arch_agnostic" - "TestArchitectures and test_restricted_arch and not test_restricted_arch_env" + # pytest's lack of exact nodeid matching or deselecting makes it impossible to nicely disable just + # test_architectures.py::TestArchitectures::test_arch (infix matching makes test_arch match test_architectures.py). + # Have to `or` for every other TestArchitectures test and then `not` that. + # What we want to disable: test_arch & test_restricted_arch + # Reason: they hardcode amd64 + "TestArchitectures and not (${ + lib.strings.concatStringsSep " or " [ + "test_arch_agnostic" + "test_default_arch" + "test_fail_arch_agnostic" + "test_fail_in_restricted_arch" + "test_restricted_arch_env" + ] + })" # no -ide images on non-x86_64 # https://gitlab.com/clickable/clickable/-/issues/478