[petsc-dev] testset + test with only args

Pierre Jolivet pierre.jolivet at enseeiht.fr
Wed Apr 22 04:04:59 CDT 2020


Hello,
Given a testset, what are the mandatory fields in the subsequent tests to have something functioning?
Here is a MWE showing that something is broken for a reason I’m not sure I understand if only the field args is provided.
$ git diff --unified=0 src/ksp/ksp/tutorials/ex1.c
diff --git a/src/ksp/ksp/tutorials/ex1.c b/src/ksp/ksp/tutorials/ex1.c
index 3b3e776a6d..59113dfd1a 100644
--- a/src/ksp/ksp/tutorials/ex1.c
+++ b/src/ksp/ksp/tutorials/ex1.c
@@ -187,0 +188,11 @@ int main(int argc,char **args)
+   testset:
+      suffix: 4
+      nsize: 1
+      args: -ksp_converged_reason -ksp_max_it 1000
+      test:
+         args:
+      test:
+         args: -ksp_type bcgs -pc_type {{hypre gamg}}
+      test:
+         args: -ksp_type gmres -pc_type {{lu ilu}}
+
$ make -f gmakefile test globsearch="ksp_ksp_tutorials-ex1_4*"
[..]
# FAILED diff-ksp_ksp_tutorials-ex1_4+a diff-ksp_ksp_tutorials-ex1_4+b+pc_type-hypre diff-ksp_ksp_tutorials-ex1_4+b+pc_type-gamg diff-ksp_ksp_tutorials-ex1_4+c+pc_type-hypre diff-ksp_ksp_tutorials-ex1_4+c+pc_type-gamg
[..]

It should be diff-ksp_ksp_tutorials-ex1_4+c+pc_type-lu diff-ksp_ksp_tutorials-ex1_4+c+pc_type-ilu, shouldn’t it?
The problem seems to go away if I explicitly put the suffixes myself, e.g., suffix: a, suffix: b, and suffix: c, cf. below, but I’d prefer to avoid having to do that.
# FAILED diff-ksp_ksp_tutorials-ex1_4_a diff-ksp_ksp_tutorials-ex1_4_c+pc_type-lu diff-ksp_ksp_tutorials-ex1_4_c+pc_type-ilu diff-ksp_ksp_tutorials-ex1_4_b+pc_type-hypre diff-ksp_ksp_tutorials-ex1_4_b+pc_type-gamg

Thanks,
Pierre


More information about the petsc-dev mailing list