EXAMINE: Extend test for empty dataset and fix bug.
[pspp] / tests / language / stats / examine.at
index 54307f4688732abb85c445ae6deb8498d6e254f1..d4540ba45d0a16b10c1908906d21547b81fee259 100644 (file)
@@ -615,7 +615,12 @@ BEGIN DATA.
 .
 END DATA.
 
-EXAMINE /x PLOT=HISTOGRAM.
+EXAMINE /x 
+       PLOT=HISTOGRAM BOXPLOT NPPLOT SPREADLEVEL(1) ALL
+       /ID=x
+        /STATISTICS = DESCRIPTIVES EXTREME (5) ALL
+       /PERCENTILE=AEMPIRICAL
+       .
 ])
 AT_CHECK([pspp -o pspp.csv examine.sps], [0], [ignore])
 dnl Ignore output -- this is just a no-crash check.
@@ -1018,3 +1023,26 @@ X,Mean,,587.6603,23.2665
 ])
 
 AT_CLEANUP 
+
+
+
+dnl Test for a crash which happened on bad input syntax
+AT_SETUP([EXAMINE -- Empty Parentheses])
+
+AT_DATA([examine-empty-parens.sps], [dnl
+DATA LIST notable LIST /X *
+BEGIN DATA.
+2
+3
+END DATA.
+
+
+EXAMINE
+       x
+       /PLOT = SPREADLEVEL()
+       .
+])
+
+AT_CHECK([pspp -o pspp.csv examine-empty-parens.sps], [1], [ignore])
+
+AT_CLEANUP