Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Slurm
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tud-zih-energy
Slurm
Commits
1a6286cf
Commit
1a6286cf
authored
19 years ago
by
Christopher J. Morrone
Browse files
Options
Downloads
Patches
Plain Diff
Streamline test and make more compatible with proctrack/linuxproc
parent
4a636447
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
testsuite/expect/test1.46
+23
-12
23 additions, 12 deletions
testsuite/expect/test1.46
with
23 additions
and
12 deletions
testsuite/expect/test1.46
+
23
−
12
View file @
1a6286cf
...
...
@@ -36,7 +36,7 @@ source ./globals
set test_id "1.46"
set exit_code 0
set file_in "test$test_id.
input
"
set file_in "test$test_id.
prog
"
set matches 0
print_header $test_id
...
...
@@ -45,19 +45,29 @@ print_header $test_id
# Delete left-over input script
# Build input script file
#
# We have
multiple sleep commands because if using
proctrack/linuxproc
,
#
the first sleep will be killed before the shell, which would
#
immediately execute the echo.
# We have
the last of the tasks exit.
proctrack/linuxproc
will not
#
signal processes named "slurmstepd" and later user tasks could still
#
be named "slurmstepd" when the termination signal comes in.
#
exec $bin_rm -f $file_in
exec echo "#!$bin_bash" >$file_in
exec echo "if ((\$SLURM_PROCID== 1))" >>$file_in
exec echo " then exit 2" >>$file_in
exec echo "fi" >>$file_in
exec echo "$bin_sleep 4" >>$file_in
exec echo "$bin_sleep 4" >>$file_in
exec echo "$bin_sleep 4" >>$file_in
exec echo "$bin_echo SHOULD_NOT_BE_HERE" >>$file_in
set fd [open "$file_in.c" w]
puts $fd {
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
main()
{
char *id = getenv("SLURM_PROCID");
if (atoi(id) == 9) {
exit(2);
}
sleep(15);
printf("SHOULD_NOT_BE_HERE\n");
}
}
close $fd
exec $bin_make -f /dev/null $file_in
exec $bin_chmod 700 $file_in
#
...
...
@@ -92,6 +102,7 @@ if {$matches != 1} {
}
if {$exit_code == 0} {
exec $bin_rm -f $file_in
#exec $bin_rm -f $file_in.c
send_user "\nSUCCESS\n"
}
exit $exit_code
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment