-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
66 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# 0022_GVMultilineComment | ||
|
||
creates a set of four replicate units with a simple binding reaction each using a network file containing a multi-line comment. | ||
|
||
## tests | ||
|
||
- cps file reads well | ||
- gv file reads well | ||
- produces an expected warning about parameter scan | ||
- produces no other warning or error | ||
- four transport reactions are created | ||
- a reaction between units 3 and 4 is not created (it is inside a comment in the network file) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/bin/bash | ||
|
||
# work out our folder name | ||
test=${PWD##*/} # to assign to a variable | ||
test=${test:-/} # to correct for the case where PWD=/ | ||
|
||
# run sbmodelr | ||
../../sbmodelr -t b -n ../sources/net4mlcomm.gv ../sources/BindingKa.cps 4 > output | ||
|
||
fail=0 | ||
|
||
# compare output and target | ||
difference=$(diff output target_stdout) | ||
if [[ $difference ]]; then | ||
printf 'FAIL %s\n' "${test}" | ||
fail=1 | ||
fi | ||
|
||
# create model summary | ||
../model_report.py BindingKa_4.cps >/dev/null | ||
if ! [[ $? = 0 ]]; then | ||
printf 'FAIL %s\n' "${test}" | ||
exit -1 | ||
fi | ||
|
||
# check that there are 4 transport reactions | ||
n=$(grep -Pc "^t_b_[12]-[234]\s+b_[12] = b_[234]" BindingKa_4.summary.txt) | ||
if ((n != 4)) ; then | ||
printf 'FAIL %s\n' "${test}" | ||
let "fail = $fail + 2" | ||
fi | ||
|
||
# check if a reaction 3 -- 4 exists | ||
if grep -Pq "^t_b_3-4\s+b_3 = b_4" BindingKa_4.summary.txt; then | ||
printf 'FAIL %s\n' "${test}" | ||
let "fail = $fail + 4" | ||
fi | ||
|
||
if [ "$fail" = 0 ] ; then | ||
printf 'PASS %s\n' "${test}" | ||
rm BindingKa_4.summary.txt output *.cps | ||
fi | ||
|
||
exit $fail |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
Processing ../sources/BindingKa.cps | ||
Reactions: 1 | ||
Species: 3 (Reactions: 3, Fixed: 0, Assignment: 0, ODE: 0) | ||
Compartments: 1 (Fixed: 1, Assignment: 0, ODE: 0) | ||
Global quantities: 3 (Fixed: 2, Assignment: 1, ODE: 0) | ||
Events: 0 (Only time-dependent: 0, variable-dependent: 0) | ||
Network: undirected (Nodes: 4, Edges: 4) | ||
Warning: in Parameter scan task the scanned or sampled items were converted to those of the first unit only. | ||
created new model BindingKa_4.cps with a set of 4 replicas of ../sources/BindingKa.cps | ||
|