FACTOR: Improve calculation of Kaiser-Meyer-Olkin and add a test
[pspp] / tests / language / stats / oneway.at
index c686f27c177ccd8c81a5bc5940bb37377ace9aec..a53dfcdd4dea0ae7e285f241c8a58ee4392bedef 100644 (file)
@@ -974,3 +974,64 @@ ONEWAY
 AT_CHECK([pspp -O format=csv crash3.sps], [0], [ignore])
 
 AT_CLEANUP
+
+
+AT_SETUP([ONEWAY Crash on empty data])
+AT_DATA([crash4.sps],[dnl
+DATA LIST NOTABLE LIST /height * weight * temperature * sex *.
+BEGIN DATA.
+1801     .       .     0
+1606     .       .     1
+END DATA.
+
+ONEWAY /VARIABLES= height weight temperature BY sex
+ /CONTRAST = -1  1
+ /CONTRAST = -3  3
+ /CONTRAST =  2 -2  1
+ /CONTRAST = -9  9
+ .
+])
+
+AT_CHECK([pspp -O format=csv crash4.sps], [0], [ignore])
+
+AT_CLEANUP
+
+
+
+AT_SETUP([ONEWAY Crash on invalid dependent variable])
+AT_DATA([crash5.sps],[dnl
+data list notable list /a * b *.
+begin data.
+3 0
+2 0
+6 2
+end data.
+
+oneway a"by b.
+
+])
+
+AT_CHECK([pspp -O format=csv crash5.sps], [1], [ignore])
+
+AT_CLEANUP
+
+
+
+
+AT_SETUP([ONEWAY Crash on unterminated string])
+
+AT_DATA([crash6.sps], [dnl
+DATA LIST NOTABLE LIST /height * weight * temperature * sex *.
+BEGIN DATA.
+1801     .       .     0
+1606     .   0   .     1
+END DATA.
+
+ONEWAY /VARIABLES= height weight temperature BY sex
+ /CONTRAST =" 2 -2  1
+ .
+])
+
+AT_CHECK([pspp -O format=csv crash6.sps], [1], [ignore])
+
+AT_CLEANUP