Skip to content

Commit d73a74f

Browse files
comiusrickeylev
andauthored
tests: make workspace CI jobs enable workspace mode (#2435)
The CI setups claiming to run in WORKSPACE mode were wrong. This fixes it. Disable integration tests on Windows WORKSPACE mode. They are failing: https://buildkite.com/bazel/rules-python-python/builds/9791#01934eac-3a03-445d-ad53-6683371ca289 Example failure: `java.lang.UnsatisfiedLinkError: 'int com.google.devtools.build.lib.windows.WindowsFileOperations.nativeIsSymlinkOrJunction(java.lang.String, boolean[], java.lang.String[])'` --------- Co-authored-by: Richard Levasseur <[email protected]>
1 parent 8ff4386 commit d73a74f

File tree

2 files changed

+26
-2
lines changed

2 files changed

+26
-2
lines changed

.bazelci/presubmit.yml

+23
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@ tasks:
132132
bazel: last_rc
133133
ubuntu_workspace:
134134
<<: *reusable_config
135+
<<: *common_workspace_flags
135136
name: "Default: Ubuntu, workspace"
136137
platform: ubuntu2004
137138
mac_workspace:
@@ -141,8 +142,30 @@ tasks:
141142
platform: macos
142143
windows_workspace:
143144
<<: *reusable_config
145+
<<: *common_workspace_flags
144146
name: "Default: Windows, workspace"
145147
platform: windows
148+
# Most of tests/integration are failing on Windows w/workspace. Skip them
149+
# for now until we can look into it.
150+
build_targets:
151+
- "--"
152+
- "..."
153+
# As a regression test for #225, check that wheel targets still build when
154+
# their package path is qualified with the repo name.
155+
- "@rules_python//examples/wheel/..."
156+
build_flags:
157+
- "--noenable_bzlmod"
158+
- "--enable_workspace"
159+
- "--keep_going"
160+
- "--build_tag_filters=-integration-test"
161+
- "--config=bazel7.x"
162+
test_targets:
163+
- "--"
164+
- "..."
165+
test_flags:
166+
- "--noenable_bzlmod"
167+
- "--enable_workspace"
168+
- "--test_tag_filters=-integration-test"
146169

147170
debian:
148171
<<: *reusable_config

tests/integration/local_toolchains/test.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ def test_python_from_path_used(self):
1818
[shell_path, "-c", "import sys; print(sys.executable)"],
1919
text=True,
2020
)
21-
expected = expected.strip()
22-
self.assertEqual(expected, sys.executable)
21+
expected = expected.strip().lower()
22+
# Normalize case: Windows may have case differences
23+
self.assertEqual(expected.lower(), sys.executable.lower())
2324

2425

2526
if __name__ == "__main__":

0 commit comments

Comments
 (0)