summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/auxiliaryFunctions/isempty/testIsEmpty.c61
1 files changed, 31 insertions, 30 deletions
diff --git a/src/auxiliaryFunctions/isempty/testIsEmpty.c b/src/auxiliaryFunctions/isempty/testIsEmpty.c
index b5e138e6..372ea976 100644
--- a/src/auxiliaryFunctions/isempty/testIsEmpty.c
+++ b/src/auxiliaryFunctions/isempty/testIsEmpty.c
@@ -5,7 +5,7 @@
** Made by Bruno JOFRET <bruno.jofret@inria.fr>
**
** Started on Wed Feb 14 16:07:57 2007 jofret
-** Last update Fri Apr 27 09:00:55 2007 jofret
+** Last update Mon Oct 22 15:56:12 2007 bruno
**
** Copyright INRIA 2007
*/
@@ -14,12 +14,10 @@
int sisemptyaTest() {
int result = 0;
-
- printf(">> Float array\n");
-
float empty[5] = {0., 0., 0., 0., 0.};
float full[5] = {1., 2., 3., 0., 0.};
+ printf(">> Float array\n");
if (sisemptya(empty, 5) == false) {
printf("ERROR ! : Test Failed (empty array)\n");
result = ERROR;
@@ -37,12 +35,10 @@ int sisemptyaTest() {
int disemptyaTest() {
int result = 0;
-
- printf(">> Double array\n");
-
double empty[5] = {0., 0., 0., 0., 0.};
double full[5] = {1., 2., 3., 0., 0.};
+ printf(">> Double array\n");
if (disemptya(empty, 5) == false) {
printf("ERROR ! : Test Failed (empty array)\n");
result = ERROR;
@@ -60,19 +56,21 @@ int disemptyaTest() {
int cisemptyaTest() {
int result = 0;
- printf(">> Float Complex array\n");
-
- floatComplex empty[5] = {FloatComplex(0., 0.),
- FloatComplex(0., 0.),
- FloatComplex(0., 0.),
- FloatComplex(0., 0.),
- FloatComplex(0., 0.)};
- floatComplex full[5] = {FloatComplex(0.,1.),
- FloatComplex(0., 2.),
- FloatComplex(0., 3.),
- FloatComplex(0., 0.),
- FloatComplex(0., 0.)};
+ floatComplex empty[5];
+ floatComplex full[5];
+
+ empty[0] = FloatComplex(0., 0.);
+ empty[1] = FloatComplex(0., 0.);
+ empty[2] = FloatComplex(0., 0.);
+ empty[3] = FloatComplex(0., 0.);
+ empty[4] = FloatComplex(0., 0.);
+ full[0] = FloatComplex(0.,1.);
+ full[1] = FloatComplex(0., 2.);
+ full[2] = FloatComplex(0., 3.);
+ full[3] = FloatComplex(0., 0.);
+ full[4] = FloatComplex(0., 0.);
+ printf(">> Float Complex array\n");
if (cisemptya(empty, 5) == false) {
printf("ERROR ! : Test Failed (empty array)\n");
result = ERROR;
@@ -91,19 +89,22 @@ int cisemptyaTest() {
int zisemptyaTest() {
int result = 0;
+ doubleComplex empty[5];
+ doubleComplex full[5];
- printf(">> Double Complex array\n");
- doubleComplex empty[5] = {DoubleComplex(0., 0.),
- DoubleComplex(0., 0.),
- DoubleComplex(0., 0.),
- DoubleComplex(0., 0.),
- DoubleComplex(0., 0.)};
- doubleComplex full[5] = {DoubleComplex(0.,1.),
- DoubleComplex(0., 2.),
- DoubleComplex(0., 3.),
- DoubleComplex(0., 0.),
- DoubleComplex(0., 0.)};
+ empty[0] = DoubleComplex(0., 0.);
+ empty[1] = DoubleComplex(0., 0.);
+ empty[2] = DoubleComplex(0., 0.);
+ empty[3] = DoubleComplex(0., 0.);
+ empty[4] = DoubleComplex(0., 0.);
+
+ full[0] = DoubleComplex(0.,1.);
+ full[1] = DoubleComplex(0., 2.);
+ full[2] = DoubleComplex(0., 3.);
+ full[3] = DoubleComplex(0., 0.);
+ full[4] = DoubleComplex(0., 0.);;
+ printf(">> Double Complex array\n");
if (zisemptya(empty, 5) == false) {
printf("ERROR ! : Test Failed (empty array)\n");
result = ERROR;