Skip to content

Commit 6af9361

Browse files
committed
ci: check expected output is obtained on module tests
Verify that the expected output is obtained when testing run/exec. Helps to determine if arguments are correctly passed over the shell alias or function defined when loading module.
1 parent 5b76d39 commit 6af9361

File tree

1 file changed

+18
-4
lines changed

1 file changed

+18
-4
lines changed

.github/workflows/test.yml

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,15 @@ jobs:
8787
8888
printf "\n\nmodule help ============================================\n"
8989
module help python/3.9.5-alpine
90-
python-exec echo donuts
91-
python-run python --version
90+
91+
python-exec echo donuts >test_output
92+
cat test_output
93+
grep --quiet donuts test_output
94+
95+
python-run python --version >test_output
96+
cat test_output
97+
grep --quiet 'Python 3.9.5' test_output
98+
rm test_output
9299
93100
- name: Run python module tests (tcsh)
94101
shell: tcsh -e {0}
@@ -121,5 +128,12 @@ jobs:
121128
122129
printf "\n\nmodule help ============================================\n"
123130
module help python/3.9.5-alpine
124-
python-exec echo donuts
125-
python-run python --version
131+
132+
python-exec echo donuts >test_output
133+
cat test_output
134+
grep --quiet donuts test_output
135+
136+
python-run python --version >test_output
137+
cat test_output
138+
grep --quiet 'Python 3.9.5' test_output
139+
rm test_output

0 commit comments

Comments
 (0)