Skip to content

Commit fd9c7d2

Browse files
authored
Skip the Muse Glimmer workload compile test on Windows (#24017)
### Problem All four Windows unit test jobs (`unittest`, `unittest-editable` and `unittest-release`, in `pull` and `trunk`) fail on `main` because of one test: ``` FAILED .ci/scripts/tests/test_muse_glimmer_batching_workload.py::MuseGlimmerBatchingWorkloadTest::test_workload_without_a_model AssertionError: unexpectedly None : CI workload tests require a C++ compiler === 1 failed, 1998 passed, 82 skipped, 14 deselected === ``` The test builds a small C++ program by running the `c++` command with GCC and Clang flags (`-std=c++17 -pthread -Werror ...`). Windows runners have no `c++` command, so the test fails at its first check. The test was added recently, and the Windows jobs were green on the commit before it. ### Fix Skip this one test on Windows. Other tests in `.ci/scripts/tests` already do this when they need Unix-only tools, for example `test_pybind_cmake.py`. On Linux and macOS nothing changes. The test still requires the compiler and still fails when it is missing. The CUDA job that this test was written for runs on Linux, so it keeps full coverage there. ### Testing - On macOS the test still builds and runs the C++ program and passes. - With `sys.platform` set to `win32` the test is skipped. - On macOS with no `c++` on `PATH` the test still fails with the same assertion, so the check is not weakened.
1 parent a39d597 commit fd9c7d2

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

‎.ci/scripts/tests/test_muse_glimmer_batching_workload.py‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import os
88
import shutil
99
import subprocess
10+
import sys
1011
import tempfile
1112
import unittest
1213
from pathlib import Path
@@ -16,6 +17,9 @@
1617

1718

1819
class MuseGlimmerBatchingWorkloadTest(unittest.TestCase):
20+
@unittest.skipIf(
21+
sys.platform == "win32", "Builds with a GCC or Clang style c++ driver"
22+
)
1923
def test_workload_without_a_model(self):
2024
compiler = shutil.which("c++")
2125
self.assertIsNotNone(compiler, "CI workload tests require a C++ compiler")

0 commit comments

Comments
 (0)