Skip to content

Commit 0d7d517

Browse files
committed
ci: some systems block Cwd changes (windows-2025 GA)
1 parent 1ddc8b4 commit 0d7d517

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

test/TestDisk.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
TestDisk < matlab.unittest.TestCase
33

44
properties
5-
CI = getenv("CI") == "true" || getenv("GITHUB_ACTIONS") == "true"
5+
CI = is_ci()
66
end
77

88
properties (TestParameter)

test/TestSubprocess.m

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
classdef (TestTags = {'R2019b'}) ...
22
TestSubprocess < matlab.unittest.TestCase
33

4+
properties
5+
CI = is_ci()
6+
end
7+
48
properties (TestParameter)
59
lang_out = {"c", "fortran"}
610
lang_in = {"cpp", "fortran"}
@@ -35,6 +39,9 @@ function test_cwd(tc)
3539

3640
[s, mc] = stdlib.subprocess_run(c, 'cwd', matlabroot, 'echo', cmd_echo);
3741
tc.assertEqual(s, 0, "status non-zero")
42+
43+
tc.assumeFalse(~strcmp(m, mc) && tc.CI, "Some CI block cwd changes")
44+
3845
tc.verifyNotEqual(m, mc, "expected different directory to have different contents")
3946

4047
end

0 commit comments

Comments
 (0)