Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
HPCasCode
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
hpc-team
HPCasCode
Commits
8653a50d
Commit
8653a50d
authored
4 years ago
by
lche0021
Browse files
Options
Downloads
Patches
Plain Diff
rename default output file
parent
3a41aff5
No related branches found
Branches containing commit
No related tags found
2 merge requests
!464
Fix listdeps
,
!442
Smoke test
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
smoke_test/generate_bin_test
+10
-10
10 additions, 10 deletions
smoke_test/generate_bin_test
with
10 additions
and
10 deletions
smoke_test/generate_bin_test
+
10
−
10
View file @
8653a50d
#!/bin/bash
# NUM_MODULE does not necessarily corresponds to the output of `ls -l $TESTCASE_DIR | wc -l` because
# 1. one folder is created for each software but NUM_MODULE pick combinations of from software/version
# 1. one folder is created for each software but NUM_MODULE pick combinations of from software/version
# 2. if a software does not modify PATH variable then there is no bintest generated for them, the number of those softwares are printed at the end
NUM_MODULE
=
${
1
:-
100
}
TESTCASE_DIR
=
'./tests'
USAGE_REPORT
=
software_usage.txt
if
[
!
-f
$USAGE_REPORT
]
;
then
software_usage
$USAGE_REPORT
fi
APPLICATION_LIST
=
'./application_list.txt'
#
USAGE_REPORT=software_usage.txt
#
if [ ! -f $USAGE_REPORT ]; then
#
software_usage $USAGE_REPORT
#
fi
echo
'#!/bin/bash
name=$( realpath $0 | xargs dirname | xargs basename )
ver=${1:-"default"}
...
...
@@ -18,7 +18,7 @@ bin_dirs=$(module show $name/$ver 2>&1 | sed -n "s/.* PATH \(.*\)/\1/p")
NAME_EXEC_EXIST=false
for bin in $bin_dirs; do
for i in $(find $bin -maxdepth 1 -executable -type f ); do
if [[ $(basename $i) == $name ]]; then
if [[ $(basename $i) == $name ]]; then
$i --version;
exit $?
fi
...
...
@@ -27,15 +27,15 @@ done
'
>
$TESTCASE_DIR
/bintest
echo
"Starting generate bintest for
$NUM_MODULE
softwares"
echo
"Starting generate bintest for
$NUM_MODULE
softwares"
declare
-i
NUM_LIB
=
0
declare
-i
GENERATED_NUM
=
0
IFS_orig
=
$IFS
IFS
=
$'
\n
'
for
i
in
$(
head
-n
$NUM_MODULE
$
USAGE_REPOR
T
)
;
do
m
=
$(
sed
-n
's/\(.*\)\/\(.*\)
- \(.*\)
/\1 \2/p'
<<<
$i
)
for
i
in
$(
head
-n
$NUM_MODULE
$
APPLICATION_LIS
T
)
;
do
m
=
$(
sed
-n
's/\(.*\)\/\(.*\)/\1 \2/p'
<<<
$i
)
name
=
$(
cut
-f1
-d
' '
<<<
$m
)
ver
=
$(
cut
-f2
-d
' '
<<<
$m
)
MODIFIED_PATH
=
$(
module show
$name
/
$ver
2>&1 |
sed
-n
's/.* PATH \(.*\)/\1/p'
)
...
...
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