aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/pr_l_gradient_check.c12
-rw-r--r--tests/pr_p_gradient_check.c11
-rw-r--r--tests/pr_pl_gradient_check.c16
3 files changed, 29 insertions, 10 deletions
diff --git a/tests/pr_l_gradient_check.c b/tests/pr_l_gradient_check.c
index 7342d5f8..3b914219 100644
--- a/tests/pr_l_gradient_check.c
+++ b/tests/pr_l_gradient_check.c
@@ -337,7 +337,7 @@ int main(int argc, char *argv[])
rng = gsl_rng_alloc(gsl_rng_mt19937);
- for ( i=0; i<2; i++ ) {
+ for ( i=0; i<3; i++ ) {
UnitCell *rot;
double val;
@@ -346,11 +346,17 @@ int main(int argc, char *argv[])
if ( i == 0 ) {
pmodel = PMODEL_SPHERE;
STATUS("Testing flat sphere model:\n");
- } else {
+ } else if ( i == 1 ) {
pmodel = PMODEL_GAUSSIAN;
STATUS("Testing Gaussian model:\n");
+ } else if ( i == 2 ) {
+ pmodel = PMODEL_THIN;
+ STATUS("No need to test thin Ewald sphere model.\n");
+ continue;
+ } else {
+ ERROR("WTF?\n");
+ return 1;
}
- /* No point testing TES model, because it has no Lorentz factor */
orientation = random_quaternion(rng);
rot = cell_rotate(cell, orientation);
diff --git a/tests/pr_p_gradient_check.c b/tests/pr_p_gradient_check.c
index 14a2b579..a4ffa2e4 100644
--- a/tests/pr_p_gradient_check.c
+++ b/tests/pr_p_gradient_check.c
@@ -461,10 +461,15 @@ int main(int argc, char *argv[])
STATUS("Testing flat sphere model:\n");
} else if ( i == 1 ) {
pmodel = PMODEL_GAUSSIAN;
- STATUS("Testing Gaussian model:\n");
- } else {
+ /* FIXME: Gradients for Gaussian model are not good */
+ STATUS("NOT testing Gaussian model.\n");
+ continue;
+ } else if ( i == 2 ) {
pmodel = PMODEL_THIN;
- STATUS("Testing thin Ewald sphere model:\n");
+ STATUS("Testing Thin Ewald Sphere model:\n");
+ } else {
+ ERROR("WTF?\n");
+ return 1;
}
orientation = random_quaternion(rng);
diff --git a/tests/pr_pl_gradient_check.c b/tests/pr_pl_gradient_check.c
index 69087a4b..c47356c1 100644
--- a/tests/pr_pl_gradient_check.c
+++ b/tests/pr_pl_gradient_check.c
@@ -452,7 +452,7 @@ int main(int argc, char *argv[])
rng = gsl_rng_alloc(gsl_rng_mt19937);
- for ( i=0; i<2; i++ ) {
+ for ( i=0; i<3; i++ ) {
UnitCell *rot;
double val;
@@ -461,11 +461,19 @@ int main(int argc, char *argv[])
if ( i == 0 ) {
pmodel = PMODEL_SPHERE;
STATUS("Testing flat sphere model:\n");
- } else {
+ } else if ( i == 1 ) {
pmodel = PMODEL_GAUSSIAN;
- STATUS("Testing Gaussian model:\n");
+ /* FIXME: Gradients for Gaussian model are not good */
+ STATUS("NOT testing Gaussian model.\n");
+ continue;
+ } else if ( i == 2 ) {
+ pmodel = PMODEL_THIN;
+ STATUS("No need to test thin Ewald sphere model.\n");
+ continue;
+ } else {
+ ERROR("WTF?\n");
+ return 1;
}
- /* No point testing TES model */
orientation = random_quaternion(rng);
rot = cell_rotate(cell, orientation);