1 AT_BANNER([system file reader - positive])
3 AT_SETUP([variable labels and missing values])
4 AT_KEYWORDS([sack synthetic system file positive])
5 AT_DATA([sys-file.sack], [dnl
7 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
9 22; dnl Nominal case size
14 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
17 dnl Numeric variable, no label or missing values.
18 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
20 dnl Numeric variable, variable label.
21 2; 0; 1; 0; 0x050800 *2; s8 "NUM2";
22 26; "Numeric variable 2's label"; i8 0 *2;
24 dnl Numeric variable, one missing value.
25 2; 0; 0; 1; 0x050800 *2; s8 "NUM3";
28 dnl Numeric variable, variable label and missing value.
29 2; 0; 1; 1; 0x050800 *2; s8 "NUM4";
30 30; "Another numeric variable label"; i8 0 * 2;
33 dnl Numeric variable, two missing values.
34 2; 0; 0; 2; 0x050800 *2; s8 "NUM5"; 1.0; 2.0;
36 dnl Numeric variable, three missing values.
37 2; 0; 0; 3; 0x050800 *2; s8 "NUM6"; 1.0; 2.0; 3.0;
39 dnl Numeric variable, range of missing values.
40 2; 0; 0; -2; 0x050800 *2; s8 "NUM7"; 1.0; 3.0;
42 dnl Numeric variables, range of missing values plus discrete value.
43 2; 0; 0; -3; 0x050800 *2; s8 "NUM8"; 1.0; 3.0; 5.0;
44 2; 0; 0; -3; 0x050800 *2; s8 "NUM9"; 1.0; HIGHEST; -5.0;
45 2; 0; 0; -3; 0x050800 *2; s8 "NUM10"; LOWEST; 1.0; 5.0;
47 dnl String variable, no label or missing values.
48 2; 4; 0; 0; 0x010400 *2; s8 "STR1";
50 dnl String variable, variable label.
51 2; 4; 1; 0; 0x010400 *2; s8 "STR2";
52 25; "String variable 2's label"; i8 0 * 3;
54 dnl String variable, one missing value.
55 2; 4; 0; 1; 0x010400 *2; s8 "STR3"; s8 "MISS";
57 dnl String variable, variable label and missing value.
58 2; 4; 1; 1; 0x010400 *2; s8 "STR4";
59 29; "Another string variable label"; i8 0 * 3;
62 dnl String variable, two missing values.
63 2; 4; 0; 2; 0x010400 *2; s8 "STR5"; s8 "MISS"; s8 "OTHR";
65 dnl String variable, three missing values.
66 2; 4; 0; 3; 0x010400 *2; s8 "STR6"; s8 "MISS"; s8 "OTHR"; s8 "MORE";
68 dnl Long string variable, one missing value.
69 2; 11; 0; 1; 0x010b00 *2; s8 "STR7"; "first8by";
70 2; -1; 0; 0; 0; 0; s8 "";
72 dnl Long string variable, value label.
73 2; 25; 1; 0; 0x011900 *2; s8 "STR8"; 14; "25-byte string"; i8 0 * 2;
74 ( 2; -1; 0; 0; 0; 0; s8 ""; ) * 2;
75 dnl Variable label fields on continuation records have been spotted in system
76 dnl files created by "SPSS Power Macintosh Release 6.1".
77 2; -1; 1; 0; 0; 0; s8 ""; 20; "dummy variable label";
79 dnl Machine integer info record.
80 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
82 dnl Machine floating-point info record.
83 7; 4; 8; 3; SYSMIS; HIGHEST; LOWEST;
85 dnl Character encoding record.
86 7; 20; 1; 12; "windows-1252";
88 dnl Dictionary termination record.
92 1.0; 2.0; 3.0; 4.0; 5.0; 6.0; 7.0; 8.0; 9.0; 10.0;
93 s8 "abcd"; s8 "efgh"; s8 "ijkl"; s8 "mnop"; s8 "qrst"; s8 "uvwx";
94 s16 "yzABCDEFGHI"; s32 "JKLMNOPQRSTUVWXYZ01234567";
97 "be e07ee28eaf7bceca017e83e9fd46be3c" \
98 "le c357aa20227c856b8a80d1b840722da1"
101 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
103 AT_DATA([sys-file.sps], [dnl
104 GET FILE='sys-file.sav'.
108 AT_CHECK([pspp -o pspp.csv sys-file.sps])
109 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
110 Variable,Description,,Position
112 num2,Numeric variable 2's label,,2
116 num4,Another numeric variable label,,4
120 ,Missing Values: 1; 2,,
122 ,Missing Values: 1; 2; 3,,
124 ,Missing Values: 1 THRU 3,,
126 ,Missing Values: 1 THRU 3; 5,,
128 ,Missing Values: 1 THRU HIGHEST; -5,,
129 num10,Format: F8.0,,10
130 ,Missing Values: LOWEST THRU 1; 5,,
132 str2,String variable 2's label,,12
135 ,"Missing Values: ""MISS""",,
136 str4,Another string variable label,,14
138 ,"Missing Values: ""OTHR""",,
140 ,"Missing Values: ""MISS""; ""OTHR""",,
142 ,"Missing Values: ""MISS""; ""OTHR""; ""MORE""",,
144 ,"Missing Values: ""first8by""",,
145 str8,25-byte string,,18
149 num1,num2,num3,num4,num5,num6,num7,num8,num9,num10,str1,str2,str3,str4,str5,str6,str7,str8
150 1,2,3,4,5,6,7,8,9,10,abcd,efgh,ijkl,mnop,qrst,uvwx,yzABCDEFGHI,JKLMNOPQRSTUVWXYZ01234567
155 AT_SETUP([unspecified number of variable positions])
156 AT_KEYWORDS([sack synthetic system file positive])
157 AT_DATA([sys-file.sack], [dnl
159 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
161 -1; dnl Nominal case size (unspecified)
162 0; dnl Not compressed
166 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
169 dnl Numeric variable, no label or missing values.
170 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
172 dnl Numeric variable, variable label.
173 2; 0; 1; 0; 0x050800 *2; s8 "NUM2";
174 26; "Numeric variable 2's label"; i8 0 *2;
176 dnl Dictionary termination record.
183 "be 413e7bc80a47fcd7e4c8020e8e120060" \
184 "le d7db9120b1ff28c83aa6fe9fc405d903"
187 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
189 AT_DATA([sys-file.sps], [dnl
190 GET FILE='sys-file.sav'.
194 AT_CHECK([pspp -o pspp.csv sys-file.sps])
195 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
196 Variable,Description,,Position
198 num2,Numeric variable 2's label,,2
208 AT_SETUP([wrong number of variable positions but version 13])
209 AT_KEYWORDS([sack synthetic system file positive])
210 AT_DATA([sys-file.sack], [dnl
212 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
214 -1; dnl Nominal case size (unspecified)
215 0; dnl Not compressed
219 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
222 dnl Numeric variable, no label or missing values.
223 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
225 dnl Numeric variable, variable label.
226 2; 0; 1; 0; 0x050800 *2; s8 "NUM2";
227 26; "Numeric variable 2's label"; i8 0 *2;
229 dnl Machine integer info record (SPSS 13).
230 7; 3; 4; 8; 13; 2; 3; -1; 1; 1; ENDIAN; 1252;
232 dnl Dictionary termination record.
239 "be 3d17aae7d99538dc73c5cb42692b1038" \
240 "le 8ad1000df598617d5258f323c882d749"
243 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
245 AT_DATA([sys-file.sps], [dnl
246 GET FILE='sys-file.sav'.
250 AT_CHECK([pspp -o pspp.csv sys-file.sps])
251 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
252 Variable,Description,,Position
254 num2,Numeric variable 2's label,,2
264 AT_SETUP([value labels])
265 AT_KEYWORDS([sack synthetic system file positive])
266 AT_DATA([sys-file.sack], [dnl
268 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
270 22; dnl Nominal case size
271 0; dnl Not compressed
275 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
278 dnl Numeric variables.
279 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
280 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
281 2; 0; 0; 0; 0x050800 *2; s8 "NUM3";
282 2; 0; 0; 0; 0x050800 *2; s8 "NUM4";
283 2; 0; 0; 0; 0x050800 *2; s8 "NUM5";
285 dnl String variables.
286 2; 1; 0; 0; 0x010100 *2; s8 "STR1"; dnl index 6
287 2; 2; 0; 0; 0x010200 *2; s8 "STR2"; dnl index 7
288 2; 3; 0; 0; 0x010300 *2; s8 "STR3"; dnl index 8
289 2; 4; 0; 0; 0x010400 *2; s8 "STR4"; dnl index 9
290 2; 4; 0; 0; 0x010400 *2; s8 "STR5"; dnl index 10
291 2; 6; 0; 0; 0x010600 *2; s8 "STR6"; dnl index 11
292 2; 7; 0; 0; 0x010700 *2; s8 "STR7"; dnl index 12
293 2; 8; 0; 0; 0x010800 *2; s8 "STR8"; dnl index 13
294 2; 9; 0; 0; 0x010900 *2; s8 "STR9"; dnl index 14
295 2; -1; 0; 0; 0; 0; s8 "";
296 2; 12; 0; 0; 0x010c00 *2; s8 "STR12"; dnl index 16
297 2; -1; 0; 0; 0; 0; s8 "";
298 2; 16; 0; 0; 0x011000 *2; s8 "STR16"; dnl index 18
299 2; -1; 0; 0; 0; 0; s8 "";
300 2; 17; 0; 0; 0x011100 *2; s8 "STR17"; dnl index 20
301 ( 2; -1; 0; 0; 0; 0; s8 ""; ) * 2;
303 dnl One value label for NUM1.
304 3; 1; 1.0; i8 3; s7 "one"; 4; 1; 1;
306 dnl Two value labels for NUM2, as a single pair of type 3 and type 4 records.
307 3; 2; 1.0; i8 3; s7 "one"; 2.0; i8 3; s7 "two"; 4; 1; 2;
309 dnl Two value labels for NUM3, as two pairs of type 3 and type 4 records.
310 3; 1; 3.0; i8 5; s7 "three"; 4; 1; 3;
311 3; 1; 4.0; i8 4; s7 "four"; 4; 1; 3;
313 dnl Two common value labels for NUM4 and NUM5, plus two different ones for each.
314 3; 1; 5.0; i8 4; s7 "five"; 4; 1; 4;
315 3; 1; 6.0; i8 3; s7 "six"; 4; 1; 5;
316 3; 2; 7.0; i8 5; s7 "seven"; 8.0; i8 5; s7 "eight"; 4; 2; 4; 5;
317 3; 1; 9.0; i8 4; s7 "nine"; 4; 1; 4;
318 3; 1; 10.0; i8 3; s7 "ten"; 4; 1; 5;
320 dnl One value label for STR1.
321 3; 1; s8 "a"; i8 19; s23 "value label for `a'"; 4; 1; 6;
323 dnl Two value labels for STR2, as a single pair of type 3 and type 4 records.
325 s8 "bc"; i8 20; s23 "value label for `bc'";
326 s8 "de"; i8 20; s23 "value label for `de'";
329 dnl Two value labels for STR3, as two pairs of type 3 and type 4 records.
330 3; 1; s8 "fgh"; i8 21; s23 "value label for `fgh'"; 4; 1; 8;
331 3; 1; s8 "ijk"; i8 21; s23 "value label for `ijk'"; 4; 1; 8;
333 dnl Two common value labels for STR4 and STR5, plus two different ones for each.
334 3; 1; s8 "lmno"; i8 22; s23 "value label for `lmno'"; 4; 1; 9;
335 3; 1; s8 "pqrs"; i8 22; s23 "value label for `pqrs'"; 4; 1; 10;
337 s8 "tuvw"; i8 22; s23 "value label for `tuvw'";
338 s8 "xyzA"; i8 22; s23 "value label for `xyzA'";
340 3; 1; s8 "BCDE"; i8 22; s23 "value label for `BCDE'"; 4; 1; 9;
341 3; 1; s8 "FGHI"; i8 22; s23 "value label for `FGHI'"; 4; 1; 10;
343 dnl One value label for STR6, STR7, STR8.
344 3; 1; s8 "JKLMNO"; i8 24; s31 "value label for `JKLMNO'"; 4; 1; 11;
345 3; 1; s8 "JKLMNOP"; i8 25; s31 "value label for `JKLMNOP'"; 4; 1; 12;
346 3; 1; s8 "JKLMNOPQ"; i8 26; s31 "value label for `JKLMNOPQ'"; 4; 1; 13;
349 dnl One value label for STR9,
350 COUNT("STR9"); 9; 1; COUNT("RSTUVWXYZ"); COUNT("value label for `RSTUVWXYZ'");
352 dnl Two value labels for STR12.
353 COUNT("STR12"); 12; 2;
354 COUNT("0123456789ab"); COUNT("value label for `0123456789ab'");
355 COUNT("cdefghijklmn"); COUNT("value label for `cdefghijklmn'");
357 dnl Three value labels for STR16.
358 COUNT("STR16"); 16; 3;
359 COUNT("opqrstuvwxyzABCD"); COUNT("value label for `opqrstuvwxyzABCD'");
360 COUNT("EFGHIJKLMNOPQRST"); COUNT("value label for `EFGHIJKLMNOPQRST'");
361 COUNT("UVWXYZ0123456789"); COUNT("value label for `UVWXYZ0123456789'");
363 dnl One value label for STR17.
364 COUNT("STR17"); 17; 1;
365 COUNT("abcdefghijklmnopq"); COUNT("value label for `abcdefghijklmnopq'");
368 dnl Dictionary termination record.
372 "be 1de55cc9fb523c8f9b014cdc5387c12b" \
373 "le 76a6974012df7351b591c5964c41e582"
376 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
378 AT_DATA([sys-file.sps], [dnl
379 GET FILE='sys-file.sav'.
382 AT_CHECK([pspp -o pspp.csv sys-file.sps])
383 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
384 Variable,Description,,Position
404 ,a,value label for `a',
406 ,bc,value label for `bc',
407 ,de,value label for `de',
409 ,fgh,value label for `fgh',
410 ,ijk,value label for `ijk',
412 ,BCDE,value label for `BCDE',
413 ,lmno,value label for `lmno',
414 ,tuvw,value label for `tuvw',
415 ,xyzA,value label for `xyzA',
417 ,FGHI,value label for `FGHI',
418 ,pqrs,value label for `pqrs',
419 ,tuvw,value label for `tuvw',
420 ,xyzA,value label for `xyzA',
422 ,JKLMNO,value label for `JKLMNO',
424 ,JKLMNOP,value label for `JKLMNOP',
426 ,JKLMNOPQ,value label for `JKLMNOPQ',
428 ,RSTUVWXYZ,value label for `RSTUVWXYZ',
429 str12,Format: A12,,15
430 ,0123456789ab,value label for `0123456789ab',
431 ,cdefghijklmn,value label for `cdefghijklmn',
432 str16,Format: A16,,16
433 ,EFGHIJKLMNOPQRST,value label for `EFGHIJKLMNOPQRST',
434 ,UVWXYZ0123456789,value label for `UVWXYZ0123456789',
435 ,opqrstuvwxyzABCD,value label for `opqrstuvwxyzABCD',
436 str17,Format: A17,,17
437 ,abcdefghijklmnopq,value label for `abcdefghijklmnopq',
442 AT_SETUP([documents])
443 AT_KEYWORDS([sack synthetic system file positive])
444 AT_DATA([sys-file.sack], [dnl
446 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
448 1; dnl Nominal case size
449 0; dnl Not compressed
453 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
456 dnl Numeric variable, no label or missing values.
457 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
461 s80 "First line of documents";
462 s80 "Second line of documents";
464 s80 "Last line of documents";
466 dnl Dictionary termination record.
473 "be 8738124d7932cc8ff803142fbf38710b" \
474 "le f3ca2123ec9e8bda91c6b865ba39f506"
477 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
479 AT_DATA([sys-file.sps], [dnl
480 GET FILE='sys-file.sav'.
484 AT_CHECK([pspp -o pspp.csv sys-file.sps])
485 AT_CHECK([cat pspp.csv], [0], [dnl
486 Documents in the active file:
488 First line of documents
490 Second line of documents
494 Last line of documents
503 AT_SETUP([multiple response sets])
504 AT_KEYWORDS([sack synthetic system file positive])
505 AT_DATA([sys-file.sack], [dnl
507 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
509 16; dnl Nominal case size
510 0; dnl Not compressed
514 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
518 2; 0; 0; 0; 0x050800 *2; s8 "A";
519 2; 0; 0; 0; 0x050800 *2; s8 "B";
520 2; 0; 0; 0; 0x050800 *2; s8 "C";
523 2; 0; 0; 0; 0x050800 *2; s8 "D";
524 2; 0; 0; 0; 0x050800 *2; s8 "E";
525 2; 0; 0; 0; 0x050800 *2; s8 "F";
526 2; 0; 0; 0; 0x050800 *2; s8 "G";
529 2; 3; 0; 0; 0x010300 *2; s8 "H";
530 2; 3; 0; 0; 0x010300 *2; s8 "I";
531 2; 3; 0; 0; 0x010300 *2; s8 "J";
534 2; 0; 0; 0; 0x050800 *2; s8 "K";
535 2; 0; 0; 0; 0x050800 *2; s8 "L";
536 2; 0; 0; 0; 0x050800 *2; s8 "M";
539 2; 6; 0; 0; 0x010600 *2; s8 "N";
540 2; 6; 0; 0; 0x010600 *2; s8 "O";
541 2; 6; 0; 0; 0x010600 *2; s8 "P";
545 "$a=C 10 my mcgroup a b c"; i8 10;
546 "$b=D2 55 0 g e f d"; i8 10;
547 "$c=D3 Yes 10 mdgroup #2 h i j"; i8 10);
551 "$d=E 1 2 34 13 third mdgroup k l m"; i8 10;
552 "$e=E 11 6 choice 0 n o p"; i8 10);
554 dnl Dictionary termination record.
558 "be 0caa3446d7a3f6985e79fd1fcc999b10" \
559 "le 9dbeba699e4149ed836f55bad7346d67"
562 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
564 AT_DATA([sys-file.sps], [dnl
565 GET FILE='sys-file.sav'.
566 MRSETS /DISPLAY NAME=ALL.
568 AT_CHECK([pspp -o pspp.csv sys-file.sps])
569 AT_CHECK([cat pspp.csv], [0], [dnl
570 Table: Multiple Response Sets
571 Name,Variables,Details
575 ","Multiple category set
582 ","Multiple dichotomy set
584 Category label source: Variable labels
589 ","Multiple dichotomy set
591 Label source: Provided by user
593 Category label source: Variable labels
598 ","Multiple dichotomy set
600 Label source: Provided by user
602 Category label source: Value labels of counted value
607 ","Multiple dichotomy set
608 Label source: First variable label among variables
609 Counted value: `choice'
610 Category label source: Value labels of counted value
616 AT_SETUP([variable display parameters, without width])
617 AT_KEYWORDS([sack synthetic system file positive])
618 AT_DATA([sys-file.sack], [dnl
620 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
622 19; dnl Nominal case size
623 0; dnl Not compressed
627 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
630 dnl Numeric variables.
631 2; 0; 0; 0; 0x050800 *2; s8 "A";
632 2; 0; 0; 0; 0x050800 *2; s8 "B";
633 2; 0; 0; 0; 0x050800 *2; s8 "C";
634 2; 0; 0; 0; 0x050800 *2; s8 "D";
636 dnl Short string variables.
637 2; 3; 0; 0; 0x010300 *2; s8 "H";
638 2; 3; 0; 0; 0x010300 *2; s8 "I";
639 2; 3; 0; 0; 0x010300 *2; s8 "J";
640 2; 3; 0; 0; 0x010300 *2; s8 "K";
642 dnl Long string variables.
643 2; 9; 0; 0; 0x010900 *2; s8 "L";
644 2; -1; 0; 0; 0; 0; s8 "";
645 2; 10; 0; 0; 0x010a00 *2; s8 "M";
646 2; -1; 0; 0; 0; 0; s8 "";
647 2; 17; 0; 0; 0x011100 *2; s8 "N";
648 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 2;
649 2; 25; 0; 0; 0x011900 *2; s8 "O";
650 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 3;
652 dnl Variable display parameters
667 dnl Dictionary termination record.
671 "be c130d9345080579b8862b360924edbfa" \
672 "le 6fde96f5a7c7386bff6cca049cd84d6a"
675 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
677 AT_DATA([sys-file.sps], [dnl
678 GET FILE='sys-file.sav'.
681 AT_CHECK([pspp -o pspp.csv sys-file.sps])
682 AT_CHECK([cat pspp.csv], [0], [dnl
683 Variable,Description,,Position
686 ,Display Alignment: Left,,
690 ,Display Alignment: Left,,
694 ,Display Alignment: Left,,
698 ,Display Alignment: Right,,
702 ,Display Alignment: Right,,
706 ,Display Alignment: Right,,
710 ,Display Alignment: Center,,
714 ,Display Alignment: Center,,
718 ,Display Alignment: Center,,
722 ,Display Alignment: Left,,
726 ,Display Alignment: Right,,
730 ,Display Alignment: Center,,
736 AT_SETUP([variable display parameters, with width])
737 AT_KEYWORDS([sack synthetic system file positive])
738 AT_DATA([sys-file.sack], [dnl
740 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
742 19; dnl Nominal case size
743 0; dnl Not compressed
747 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
750 dnl Numeric variables.
751 2; 0; 0; 0; 0x050800 *2; s8 "A";
752 2; 0; 0; 0; 0x050800 *2; s8 "B";
753 2; 0; 0; 0; 0x050800 *2; s8 "C";
754 2; 0; 0; 0; 0x050800 *2; s8 "D";
756 dnl Short string variables.
757 2; 3; 0; 0; 0x010300 *2; s8 "H";
758 2; 3; 0; 0; 0x010300 *2; s8 "I";
759 2; 3; 0; 0; 0x010300 *2; s8 "J";
760 2; 3; 0; 0; 0x010300 *2; s8 "K";
762 dnl Long string variables.
763 2; 9; 0; 0; 0x010900 *2; s8 "L";
764 2; -1; 0; 0; 0; 0; s8 "";
765 2; 10; 0; 0; 0x010a00 *2; s8 "M";
766 2; -1; 0; 0; 0; 0; s8 "";
767 2; 17; 0; 0; 0x011100 *2; s8 "N";
768 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 2;
769 2; 25; 0; 0; 0x011900 *2; s8 "O";
770 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 3;
772 dnl Variable display parameters
787 dnl Dictionary termination record.
791 "be 3ace75689a0b7faa9360936bbfe26055" \
792 "le 6e93f35d19a9882eb53ffb1b067ef7cd"
795 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
797 AT_DATA([sys-file.sps], [dnl
798 GET FILE='sys-file.sav'.
801 AT_CHECK([pspp -o pspp.csv sys-file.sps])
802 AT_CHECK([cat pspp.csv], [0], [dnl
803 Variable,Description,,Position
806 ,Display Alignment: Left,,
810 ,Display Alignment: Left,,
814 ,Display Alignment: Left,,
818 ,Display Alignment: Right,,
822 ,Display Alignment: Right,,
826 ,Display Alignment: Right,,
830 ,Display Alignment: Center,,
834 ,Display Alignment: Center,,
838 ,Display Alignment: Center,,
842 ,Display Alignment: Left,,
846 ,Display Alignment: Right,,
850 ,Display Alignment: Center,,
856 AT_SETUP([long variable names])
857 AT_KEYWORDS([sack synthetic system file positive])
858 AT_DATA([sys-file.sack], [dnl
860 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
862 4; dnl Nominal case size
863 0; dnl Not compressed
867 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
870 dnl Numeric variables.
871 2; 0; 0; 0; 0x050800 *2; s8 "LONGVARI";
872 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_A";
873 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_B";
874 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_C";
876 dnl Long variable names.
878 "LONGVARI=LongVariableName1"; i8 9;
879 "LONGVA_A=LongVariableName2"; i8 9;
880 "LONGVA_B=LongVariableName3"; i8 9;
881 "LONGVA_C=LongVariableName4";
884 dnl Dictionary termination record.
888 "be eb7a8b4055a5d880a185a566048876b3" \
889 "le dd4ecd7541320b9b51746717ef20973f"
892 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
894 AT_DATA([sys-file.sps], [dnl
895 GET FILE='sys-file.sav'.
898 AT_CHECK([pspp -o pspp.csv sys-file.sps])
899 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
900 Variable,Description,,Position
901 LongVariableName1,Format: F8.0,,1
902 LongVariableName2,Format: F8.0,,2
903 LongVariableName3,Format: F8.0,,3
904 LongVariableName4,Format: F8.0,,4
909 AT_SETUP([very long strings])
910 AT_KEYWORDS([sack synthetic system file positive])
911 AT_DATA([sys-file.sack], [dnl
913 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
915 109; dnl Nominal case size
916 0; dnl Not compressed
920 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
924 2; 255; 0; 0; 0x01FF00 *2; s8 "STR256";
925 (2; -1; 0; 0; 0; 0; s8 "") * 31;
926 2; 4; 0; 0; 0x010400 *2; s8 "STR256_1";
929 2; 255; 0; 0; 0x01FF00 *2; s8 "STR600";
930 (2; -1; 0; 0; 0; 0; s8 "") * 31;
931 2; 255; 0; 0; 0x01FF00 *2; s8 "STR600_1";
932 (2; -1; 0; 0; 0; 0; s8 "") * 31;
933 2; 96; 0; 0; 0x016000 *2; s8 "STR600_2";
934 (2; -1; 0; 0; 0; 0; s8 "") * 11;
936 dnl Very long string record.
938 "STR256=00256"; i8 0; i8 9;
939 "STR600=00600"; i8 0; i8 9;
942 dnl Dictionary termination record.
946 "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#" * 4;
948 "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#" * 9;
949 "abcdefghijklmnopqrstuvwxyzABCDEF";
952 "be 40a4327805d8b59891084317248f5d4a" \
953 "le ced2584a43037b893b7feb068e2cb9d6"
956 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
958 AT_DATA([sys-file.sps], [dnl
959 GET FILE='sys-file.sav'.
963 AT_CHECK([pspp -o pspp.csv sys-file.sps])
964 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
965 Variable,Description,,Position
966 str256,Format: A256,,1
967 str600,Format: A600,,2
971 abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@a,abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyz
976 AT_SETUP([data file and variable attributes])
977 AT_KEYWORDS([sack synthetic system file positive])
978 AT_DATA([sys-file.sack], [dnl
980 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
982 2; dnl Nominal case size
983 0; dnl Not compressed
987 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
991 2; 0; 0; 0; 0x050800 *2; s8 "FIRSTVAR";
992 2; 0; 0; 0; 0x050800 *2; s8 "SECONDVA";
994 dnl Long variable names.
996 "FIRSTVAR=FirstVariable"; i8 9;
997 "SECONDVA=SecondVariable"; i8 9;
1000 dnl Data file attributes record.
1002 "Attr1('Value1'"; i8 10; "''QuotedValue''"; i8 10; ")";
1003 "SecondAttr('123'"; i8 10; "'456'"; i8 10; ")";
1006 dnl Variable attributes record.
1009 "fred('23'"; i8 10; "'34'"; i8 10; ")";
1010 "bert('123'"; i8 10; ")";
1012 "xyzzy('quux'"; i8 10; ")";
1015 dnl Dictionary termination record.
1019 "be 955802de462daf810c0ecc81ee2320a1" \
1020 "le 7fc6439aedfa00615bb1fe94d6701305"
1023 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1025 AT_DATA([sys-file.sps], [dnl
1026 GET FILE='sys-file.sav'.
1029 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1030 AT_CHECK([cat pspp.csv], [0],
1031 [[Variable,Description,
1032 FirstVariable,Custom attributes:,
1036 SecondVariable,Custom attributes:,
1039 Table: Custom data file attributes.
1044 Attr1[2],'QuotedValue'
1049 AT_SETUP([compressed data])
1050 AT_KEYWORDS([sack synthetic system file positive])
1051 AT_DATA([sys-file.sack], [dnl
1053 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1055 6; dnl Nominal case size
1056 1; dnl Not compressed
1058 -1; dnl Unspecified number of cases.
1060 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1063 dnl Numeric variables.
1064 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1065 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
1067 dnl String variable.
1068 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
1069 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
1070 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
1071 2; -1; 0; 0; 0; 0; s8 "";
1073 dnl Dictionary termination record.
1076 dnl Compressed data.
1077 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
1078 i8 253 253 253 254; i8 101 102 253 253; s8 "jklm"; s8 "nopqrstu";
1079 s8 "vwxyzABC"; s8 "DEFG"; s8 "HIJKLMNO";
1080 i8 254 253 252 0 0 0 0 0; s8 "PQRSTUVW";
1084 "be c0670e436b068f45710b98f6f7d01dc5" \
1085 "le 2e43a7f8861df4e714a192dfb3c8b2f4"
1088 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1090 AT_DATA([sys-file.sps], [dnl
1091 GET FILE='sys-file.sav'.
1095 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1096 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1097 Variable,Description,,Position
1098 num1,Format: F8.0,,1
1099 num2,Format: F8.0,,2
1102 str15,Format: A15,,5
1105 num1,num2,str4,str8,str15
1106 -99,0,,abcdefgh,0123 @&t@
1107 .,151,jklm,nopqrstu,vwxyzABC @&t@
1108 1,2,DEFG,HIJKLMNO,PQRSTUV
1113 AT_SETUP([compressed data, zero bias])
1114 AT_KEYWORDS([sack synthetic system file positive])
1115 AT_DATA([sys-file.sack], [dnl
1117 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1119 6; dnl Nominal case size
1120 1; dnl Not compressed
1122 -1; dnl Unspecified number of cases.
1124 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1127 dnl Numeric variables.
1128 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1129 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
1131 dnl String variable.
1132 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
1133 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
1134 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
1135 2; -1; 0; 0; 0; 0; s8 "";
1137 dnl Dictionary termination record.
1140 dnl Compressed data.
1141 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
1142 i8 253 253 253 254; i8 101 102 253 253; s8 "jklm"; s8 "nopqrstu";
1143 s8 "vwxyzABC"; s8 "DEFG"; s8 "HIJKLMNO";
1144 i8 254 253 252 0 0 0 0 0; s8 "PQRSTUVW";
1148 "be 2f0d25704ee497ae833213a3e4ff5e8b" \
1149 "le 49f68a9e1ba02a2f7e9166686a0db9d9"
1152 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1154 AT_DATA([sys-file.sps], [dnl
1155 GET FILE='sys-file.sav'.
1159 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0])
1160 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1161 Variable,Description,,Position
1162 num1,Format: F8.0,,1
1163 num2,Format: F8.0,,2
1166 str15,Format: A15,,5
1169 num1,num2,str4,str8,str15
1170 1,100,,abcdefgh,0123 @&t@
1171 .,251,jklm,nopqrstu,vwxyzABC @&t@
1172 101,102,DEFG,HIJKLMNO,PQRSTUV
1177 AT_SETUP([compressed data, other bias])
1178 AT_KEYWORDS([sack synthetic system file positive])
1179 AT_DATA([sys-file.sack], [dnl
1181 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1183 6; dnl Nominal case size
1184 1; dnl Not compressed
1186 -1; dnl Unspecified number of cases.
1188 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1191 dnl Numeric variables.
1192 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1193 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
1195 dnl String variable.
1196 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
1197 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
1198 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
1199 2; -1; 0; 0; 0; 0; s8 "";
1201 dnl Dictionary termination record.
1204 dnl Compressed data.
1205 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
1206 i8 253 253 253 254; i8 101 102 253 253; s8 "jklm"; s8 "nopqrstu";
1207 s8 "vwxyzABC"; s8 "DEFG"; s8 "HIJKLMNO";
1208 i8 254 253 252 0 0 0 0 0; s8 "PQRSTUVW";
1212 "be 668b85e3dee0797883e9933a096b8c18" \
1213 "le 5e7a9c4e88cd2dbc2322943da663868e"
1216 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1218 AT_DATA([sys-file.sps], [dnl
1219 GET FILE='sys-file.sav'.
1223 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0],
1224 [warning: `sys-file.sav' near offset 0x54: Compression bias is not the usual value of 100, or system file uses unrecognized floating-point format.
1226 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1227 "warning: `sys-file.sav' near offset 0x54: Compression bias is not the usual value of 100, or system file uses unrecognized floating-point format."
1229 Variable,Description,,Position
1230 num1,Format: F8.0,,1
1231 num2,Format: F8.0,,2
1234 str15,Format: A15,,5
1237 num1,num2,str4,str8,str15
1238 -49,50,,abcdefgh,0123 @&t@
1239 .,201,jklm,nopqrstu,vwxyzABC @&t@
1240 51,52,DEFG,HIJKLMNO,PQRSTUV
1245 AT_BANNER([system file reader - negative])
1247 AT_SETUP([misplaced type 4 record])
1248 AT_KEYWORDS([sack synthetic system file negative])
1249 AT_DATA([sys-file.sack], [dnl
1251 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1252 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1254 dnl Numeric variable.
1255 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1261 "be 6e0bb549fff1fd1af333d51b8a6e0f43" \
1262 "le 7b62734edcee2a1689c463f2866d11b8"
1265 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1267 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1269 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1270 [error: `sys-file.sav' near offset 0xd4: Misplaced type 4 record.
1272 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1277 AT_SETUP([bad record type])
1278 AT_KEYWORDS([sack synthetic system file negative])
1279 AT_DATA([sys-file.sack], [dnl
1281 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1282 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1284 dnl Numeric variable.
1285 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1287 dnl Type 8 record (not a valid type).
1291 "be dc8f078c23046ee7db74ec1003178a11" \
1292 "le dc7f111642f0629f4370630fd092eee3"
1295 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1297 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1299 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1300 [error: `sys-file.sav' near offset 0xd4: Unrecognized record type 8.
1302 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1307 AT_SETUP([wrong number of variable positions])
1308 AT_KEYWORDS([sack synthetic system file negative])
1309 AT_DATA([sys-file.sack], [dnl
1311 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1312 2; >>2<<; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1314 dnl Numeric variable.
1315 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1317 dnl End of dictionary.
1321 "be c57e91aa426f61813c3ad91ea3a56dda" \
1322 "le 5d1a6c114b135b219473c8ad5bb44bda"
1325 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1327 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1329 AT_CHECK([pspp -O format=csv sys-file.sps], [0],
1330 [warning: `sys-file.sav': File header claims 2 variable positions but 1 were read from file.
1335 AT_SETUP([variable name may not begin with `#'])
1336 AT_KEYWORDS([sack synthetic system file negative])
1337 AT_DATA([sys-file.sack], [dnl
1339 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1340 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1342 dnl Numeric variable.
1343 2; 0; 0; 0; 0x050800 *2; s8 >>"$UM1"<<;
1345 dnl End of dictionary.
1349 "be decb7ac6defa1ab3cc7a386d1843c1ae" \
1350 "le 5279b6275633bac55d167faebccfdb14"
1353 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1355 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1357 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1358 [error: `sys-file.sav' near offset 0xb4: Invalid variable name `$UM1'.
1360 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1365 AT_SETUP([variable name may not be reserved word])
1366 AT_KEYWORDS([sack synthetic system file negative])
1367 AT_DATA([sys-file.sack], [dnl
1369 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1370 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1372 dnl Numeric variable.
1373 2; 0; 0; 0; 0x050800 *2; s8 >>"TO"<<;
1375 dnl End of dictionary.
1379 "be 57e6ad709668bbf538e2efee4af49916" \
1380 "le 523f14b611efa380bbadf7a16ea43fed"
1383 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1385 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1387 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1388 [error: `sys-file.sav' near offset 0xb4: Invalid variable name `TO'.
1390 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1395 AT_SETUP([variable width must be between 0 and 255])
1396 AT_KEYWORDS([sack synthetic system file negative])
1397 AT_DATA([sys-file.sack], [dnl
1399 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1400 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1402 dnl String variable with invalid width 256.
1403 2; 256; 0; 0; 0x050800 *2; s8 "VAR1";
1405 dnl End of dictionary.
1409 "be 170bb18589ba264a0ed2d57b41fe77e1" \
1410 "le 9528b4b5936ef5630bbd3bdd60a123c3"
1413 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1415 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1417 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1418 [error: `sys-file.sav' near offset 0xb4: Bad width 256 for variable VAR1.
1420 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1425 AT_SETUP([duplicate variable name])
1426 AT_KEYWORDS([sack synthetic system file negative])
1427 AT_DATA([sys-file.sack], [dnl
1429 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1430 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1432 dnl Numeric variables.
1433 2; 0; 0; 0; 0x050800 *2; s8 "VAR1";
1434 2; 0; 0; 0; 0x050800 *2; s8 "VAR1";
1436 dnl End of dictionary.
1440 "be d8f5fd768ab1d641f9330a4840c71343" \
1441 "le f01e123d384cdaa7c2f7fc4791325ebf"
1444 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1446 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1448 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1449 [error: `sys-file.sav' near offset 0xd4: Duplicate variable name `VAR1'.
1451 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1456 AT_SETUP([variable label indicator not 0 or 1])
1457 AT_KEYWORDS([sack synthetic system file negative])
1458 AT_DATA([sys-file.sack], [dnl
1460 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1461 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1463 dnl Numeric variable.
1464 2; 0; >>2<<; 0; 0x050800 *2; s8 "VAR1";
1466 dnl End of dictionary.
1470 "be 3c5ff8d8f146457a385ca92d3d23ca8a" \
1471 "le 37e9f956d321ae57b0bf7fe2384e892b"
1474 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1476 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1478 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1479 [error: `sys-file.sav' near offset 0xb4: Variable label indicator field is not 0 or 1.
1481 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1486 AT_SETUP([invalid numeric missing value indicator])
1487 AT_KEYWORDS([sack synthetic system file negative])
1488 AT_DATA([sys-file.sack], [dnl
1490 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1491 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1493 dnl Numeric variable.
1494 2; 0; 0; >>-1<<; 0x050800 *2; s8 "VAR1";
1496 dnl End of dictionary.
1500 "be d1d0d4aedf9f053452c4b1e658ade5e2" \
1501 "le df697575499fe12921185a3d23a5d61d"
1504 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1506 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1508 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1509 ["error: `sys-file.sav' near offset 0xb4: Numeric missing value indicator field is not -3, -2, 0, 1, 2, or 3."
1511 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1516 AT_SETUP([invalid string missing value indicator])
1517 AT_KEYWORDS([sack synthetic system file negative])
1518 AT_DATA([sys-file.sack], [dnl
1520 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1521 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1523 dnl String variable.
1524 2; 8; 0; >>4<<; 0x010800 *2; s8 "VAR1";
1526 dnl End of dictionary.
1530 "be f833033be7b102fae19159989f62faa6" \
1531 "le 9704ba828bb7a36ef0262838f6b7936b"
1534 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1536 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1538 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1539 ["error: `sys-file.sav' near offset 0xb4: String missing value indicator field is not 0, 1, 2, or 3."
1541 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1546 AT_SETUP([missing string continuation record])
1547 AT_KEYWORDS([sack synthetic system file negative])
1548 AT_DATA([sys-file.sack], [dnl
1550 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1551 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1553 dnl String variable.
1554 2; 10; 0; 0; 0x010a00 *2; s8 "VAR1";
1555 >>2; 0; 0; 0; 0x050800 *2; s8 "VAR2";<<
1557 dnl End of dictionary.
1561 "be c8f9ad2b2acd2918055e2b78c1e0b4b8" \
1562 "le 1afab4d6aee90a6fe8d2dbf229e06409"
1565 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1567 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1569 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1570 [error: `sys-file.sav' near offset 0xb4: Missing string continuation record.
1572 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1577 AT_SETUP([unknown variable format])
1578 AT_KEYWORDS([sack synthetic system file negative])
1579 AT_DATA([sys-file.sack], [dnl
1581 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1582 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1584 dnl Numeric variable.
1585 2; 0; 0; 0; >>0xff0800<< *2; s8 "VAR1";
1587 dnl End of dictionary.
1591 "be fcf94b3ff11b7e2ff50c226b609cff1e" \
1592 "le 88fc97cc80d5a170e53a7cc89e204b0d"
1595 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1597 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1599 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1600 [error: `sys-file.sav' near offset 0xc0: Unknown variable format 255.
1602 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1607 AT_SETUP([invalid numeric variable format])
1608 AT_KEYWORDS([sack synthetic system file negative])
1609 AT_DATA([sys-file.sack], [dnl
1611 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1612 2; 3; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1614 dnl Numeric variable, string formats.
1615 2; 0; 0; 0; >>0x010800<<; >>0x021000<<; s8 "VAR1";
1617 dnl String variable, numeric formats.
1618 2; 4; 0; 0; >>0x050800<<; >>0x110a01<<; s8 "STR1";
1620 dnl String variable, wrong width formats.
1621 2; 4; 0; 0; >>0x010800<<; >>0x020400<<; s8 "STR2";
1623 dnl End of dictionary.
1627 "be 0c36a39ec9118eb4a83f10a9483b5a37" \
1628 "le 1d498d60eeb2c88e0479f113fb3ffe4b"
1631 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1633 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1635 AT_CHECK([pspp -O format=csv sys-file.sps], [0],
1636 [warning: `sys-file.sav' near offset 0xc0: Numeric variable VAR1 has invalid print format A8.
1638 warning: `sys-file.sav' near offset 0xc4: Numeric variable VAR1 has invalid write format AHEX16.
1640 warning: `sys-file.sav' near offset 0xe0: String variable STR1 has invalid print format F8.0.
1642 warning: `sys-file.sav' near offset 0xe4: String variable STR1 has invalid write format E10.1.
1644 warning: `sys-file.sav' near offset 0x100: String variable STR2 has invalid print format A8.
1646 warning: `sys-file.sav' near offset 0x104: String variable STR2 has invalid write format AHEX4.
1651 AT_SETUP([weighting variable must be numeric])
1652 AT_KEYWORDS([sack synthetic system file negative])
1653 AT_DATA([sys-file.sack], [dnl
1655 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1656 2; 2; 1; >>2<<; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1658 dnl Numeric variable.
1659 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1661 dnl String variable.
1662 2; 4; 0; 0; 0x010400 *2; s8 "STR1";
1664 dnl End of dictionary.
1668 "be 82d30105e46c4896c24f9dcec26c4749" \
1669 "le 32e235119be70050eb78bf4186a5a046"
1672 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1674 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1676 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1677 [error: `sys-file.sav': Weighting variable must be numeric (not string variable `STR1').
1679 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1684 AT_SETUP([bad weighting variable index])
1685 AT_KEYWORDS([sack synthetic system file negative])
1686 AT_DATA([sys-file.sack], [dnl
1688 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1689 2; 2; 1; >>3<<; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1691 dnl Numeric variable.
1692 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1694 dnl String variable.
1695 2; 4; 0; 0; 0x010400 *2; s8 "STR1";
1697 dnl End of dictionary.
1701 "be cd9af924ff20bc75834aa2c696254c97" \
1702 "le cbe0f2f514f5e95f27644d0b4314bc78"
1705 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1707 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1709 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1710 [error: `sys-file.sav' near offset 0x4c: Variable index 3 not in valid range 1...2.
1712 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1717 AT_SETUP([variable index is long string contination])
1718 AT_KEYWORDS([sack synthetic system file negative])
1719 AT_DATA([sys-file.sack], [dnl
1721 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1722 2; 2; 1; >>3<<; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1724 dnl Numeric variable.
1725 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1727 dnl Long string variable.
1728 2; 9; 0; 0; 0x010900 *2; s8 "STR1";
1729 (2; -1; 0; 0; 0; 0; s8 "");
1731 dnl End of dictionary.
1735 "be 0c395354df56ea5ff374aafcc535d633" \
1736 "le d977f684ea9d4648ed40f8c6dddde9f7"
1739 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1741 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1743 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1744 [error: `sys-file.sav' near offset 0x4c: Variable index 3 refers to long string continuation.
1746 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1751 AT_SETUP([multiple documents records])
1752 AT_KEYWORDS([sack synthetic system file negative])
1753 AT_DATA([sys-file.sack], [dnl
1755 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1756 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1758 dnl Numeric variable, no label or missing values.
1759 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1761 dnl Two document records.
1762 (6; 1; s80 "One line of documents") >>* 2<<;
1764 dnl Dictionary termination record.
1771 "be 18aa3348a216ed494efe28285b348fa8" \
1772 "le 19b21522bcef1dcc60af328f923f307e"
1775 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1777 AT_DATA([sys-file.sps], [dnl
1778 GET FILE='sys-file.sav'.
1780 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
1781 error: `sys-file.sav' near offset 0x12c: Duplicate type 6 (document) record.
1783 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1789 AT_SETUP([empty document record])
1790 AT_KEYWORDS([sack synthetic system file negative])
1791 AT_DATA([sys-file.sack], [dnl
1793 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1794 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1796 dnl Numeric variable, no label or missing values.
1797 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1799 dnl Empty document record.
1802 dnl Dictionary termination record.
1809 "be d8ef29c1b97f9ed226cbd938c9c49b6e" \
1810 "le f6a560c5b62e2c472429d85294f36e61"
1813 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1815 AT_DATA([sys-file.sps], [dnl
1816 GET FILE='sys-file.sav'.
1818 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
1819 error: `sys-file.sav' near offset 0xd4: Number of document lines (0) must be greater than 0 and less than 26843545.
1821 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1826 AT_SETUP([extension record too large])
1827 AT_KEYWORDS([sack synthetic system file negative])
1828 AT_DATA([sys-file.sack], [dnl
1830 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1831 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1833 dnl Numeric variable, no label or missing values.
1834 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1836 dnl Too-large extension record.
1837 7; 3; >>0xfffff000 * 2<<;
1840 "be 5a6679dc41ac349b0b73fc430937c05c" \
1841 "le d4769c7f650cfbf160e0386d0d33be04"
1844 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1846 AT_DATA([sys-file.sps], [dnl
1847 GET FILE='sys-file.sav'.
1849 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
1850 error: `sys-file.sav' near offset 0xd8: Record type 7 subtype 3 too large.
1852 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1857 AT_SETUP([unknown extension record])
1858 AT_KEYWORDS([sack synthetic system file negative])
1859 AT_DATA([sys-file.sack], [dnl
1861 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1862 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1864 dnl Numeric variable, no label or missing values.
1865 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1867 dnl Unknown extension record type.
1870 dnl End of dictionary.
1874 "be ac8395e27677408189bcb8655e56cc0e" \
1875 "le e308bfcd51f1e3c28d7379c29271f9d6"
1878 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1880 AT_DATA([sys-file.sps], [dnl
1881 GET FILE='sys-file.sav'.
1883 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
1884 "warning: `sys-file.sav' near offset 0xd8: Unrecognized record type 7, subtype 30. Please send a copy of this file, and the syntax which created it to bug-gnu-pspp@gnu.org."
1889 AT_SETUP([bad machine integer info size])
1890 AT_KEYWORDS([sack synthetic system file negative])
1891 AT_DATA([sys-file.sack], [dnl
1893 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1894 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1896 dnl Numeric variable, no label or missing values.
1897 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1899 dnl Machine integer info record.
1900 7; 3; 4; >>9<<; 1; 2; 3; -1; 1; 1; ENDIAN; 1252; >>1234<<;
1902 dnl End of dictionary.
1906 "be 21ec84826886b0a266d1360f8279d769" \
1907 "le 15dcba7b2b89b7d8a21ebcc872f515af"
1910 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
1911 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1913 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
1914 "warning: `sys-file.sav' near offset 0xd8: Record type 7, subtype 3 has bad count 9 (expected 8)."
1919 AT_SETUP([bad machine integer info float format])
1920 AT_KEYWORDS([sack synthetic system file negative])
1921 AT_DATA([sys-file.sack], [dnl
1923 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1924 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1926 dnl Numeric variable, no label or missing values.
1927 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1929 dnl Machine integer info record.
1930 7; 3; 4; 8; 1; 2; 3; -1; >>2<<; 1; ENDIAN; 1252;
1932 dnl End of dictionary.
1936 "be d510ed28278649eee997fb6881a4c04f" \
1937 "le fbf1eca561a4e243b7ae844ed1677035"
1940 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
1941 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1943 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
1944 error: `sys-file.sav' near offset 0xd8: Floating-point representation indicated by system file (2) differs from expected (1).
1946 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
1951 AT_SETUP([bad machine integer info endianness])
1952 AT_KEYWORDS([sack synthetic system file negative])
1953 AT_DATA([sys-file.sack], [dnl
1955 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1956 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1958 dnl Numeric variable, no label or missing values.
1959 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1961 dnl Machine integer info record.
1962 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; >>3<<; 1252;
1964 dnl End of dictionary.
1968 "be 855123d16d5e1560b91d60753dad79ad 1" \
1969 "le d6626b4fa2e46a91f26c2fc609b2f1e0 2"
1972 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1974 AT_DATA([sys-file.sps], [dnl
1975 GET FILE='sys-file.sav'.
1978 AT_CHECK_UNQUOTED([pspp -O format=csv sys-file.sps], [0], [dnl
1979 warning: \`sys-file.sav' near offset 0xd8: Integer format indicated by system file (3) differs from expected ($[3]).
1981 Variable,Description,,Position
1982 num1,Format: F8.0,,1
1984 ,Display Alignment: Right,,
1991 AT_SETUP([bad machine floating-point info size])
1992 AT_KEYWORDS([sack synthetic system file negative])
1993 AT_DATA([sys-file.sack], [dnl
1995 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1996 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1998 dnl Numeric variable, no label or missing values.
1999 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2001 dnl Machine floating-point info record.
2002 7; 4; 8; >>4<<; SYSMIS; HIGHEST; LOWEST; 0.0;
2004 dnl End of dictionary.
2008 "be 29c9a173638fbb8bb1efe1176c4d670f" \
2009 "le 5cb49eb1084e5b9cd573a54705ff86a7"
2012 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
2013 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2015 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2016 "warning: `sys-file.sav' near offset 0xd8: Record type 7, subtype 4 has bad count 4 (expected 3)."
2021 AT_SETUP([wrong special floating point values])
2022 AT_KEYWORDS([sack synthetic system file negative])
2023 AT_DATA([sys-file.sack], [dnl
2025 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2026 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2028 dnl Numeric variable, no label or missing values.
2029 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2031 dnl Machine floating-point info record.
2032 7; 4; 8; 3; >>0.0<<; >>1.0<<; >>2.0<<;
2034 dnl End of dictionary.
2038 "be 1e7452d9bb0a2397bf6084a25437514e" \
2039 "le f59f9a83f723cde1611869ff6d91d325"
2042 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2044 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2046 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2047 warning: `sys-file.sav' near offset 0xd8: File specifies unexpected value 0 as SYSMIS.
2049 warning: `sys-file.sav' near offset 0xd8: File specifies unexpected value 1 as HIGHEST.
2051 warning: `sys-file.sav' near offset 0xd8: File specifies unexpected value 2 as LOWEST.
2056 AT_SETUP([bad mrsets name])
2057 AT_KEYWORDS([sack synthetic system file negative multiple response])
2058 AT_DATA([sys-file.sack], [dnl
2060 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2061 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2063 dnl Numeric variable, no label or missing values.
2064 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2066 dnl Multiple response sets.
2067 7; 7; 1; COUNT("a=C");
2068 7; 19; 1; COUNT("xyz=D");
2073 "be 15a9bf44d0cd6186a60629b77079c5a5" \
2074 "le 161c99aca5e7a3684df096137e72ce5b"
2077 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2079 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2081 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2082 warning: `sys-file.sav' near offset 0xd8: `a' does not begin with `$' at UTF-8 offset 2 in MRSETS record.
2084 warning: `sys-file.sav' near offset 0xeb: `xyz' does not begin with `$' at UTF-8 offset 4 in MRSETS record.
2089 AT_SETUP([missing space after C in mrsets])
2090 AT_KEYWORDS([sack synthetic system file negative multiple response])
2091 AT_DATA([sys-file.sack], [dnl
2093 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2094 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2096 dnl Numeric variable, no label or missing values.
2097 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2099 dnl Multiple response sets.
2100 7; 7; 1; COUNT("$a=Cx");
2105 "be c5e5656ba3d74c3a967850f29ad89970" \
2106 "le 29f110509c3d6893a7d21ae2d66aad9d"
2109 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2111 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2113 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2114 warning: `sys-file.sav' near offset 0xd8: Missing space following `C' at UTF-8 offset 4 in MRSETS record.
2119 AT_SETUP([missing space after E in mrsets])
2120 AT_KEYWORDS([sack synthetic system file negative multiple response])
2121 AT_DATA([sys-file.sack], [dnl
2123 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2124 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2126 dnl Numeric variable, no label or missing values.
2127 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2129 dnl Multiple response sets.
2130 7; 7; 1; COUNT("$a=Ex");
2135 "be a9e1dc63e2524882a5e3d2949a2da9d4" \
2136 "le ac709ca1928f65f47a8c8efdd9454b50"
2139 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2141 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2143 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2144 warning: `sys-file.sav' near offset 0xd8: Missing space following `E' at UTF-8 offset 4 in MRSETS record.
2149 AT_SETUP([unexpected label source in mrsets])
2150 AT_KEYWORDS([sack synthetic system file negative multiple response])
2151 AT_DATA([sys-file.sack], [dnl
2153 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2154 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2156 dnl Numeric variable, no label or missing values.
2157 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2159 dnl Multiple response sets.
2160 7; 7; 1; COUNT("$a=E 2");
2165 "be 8c710e85a0a1609d0d03dec80aaf5f94" \
2166 "le 4682440b82f22d4bd2ac56afb7fa3152"
2169 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2171 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2173 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2174 warning: `sys-file.sav' near offset 0xd8: Unexpected label source value `2' following `E' at UTF-8 offset 7 in MRSETS record.
2176 warning: `sys-file.sav' near offset 0xd8: Expecting digit at UTF-8 offset 7 in MRSETS record.
2181 AT_SETUP([bad type character in mrsets])
2182 AT_KEYWORDS([sack synthetic system file negative multiple response])
2183 AT_DATA([sys-file.sack], [dnl
2185 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2186 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2188 dnl Numeric variable, no label or missing values.
2189 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2191 dnl Multiple response sets.
2192 7; 7; 1; COUNT("$a=");
2197 "be fc5e5200d8f56b9a5a713e4a95313a3b" \
2198 "le 578a61e8a06b20216612f566c2050879"
2201 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2203 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2205 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2206 "warning: `sys-file.sav' near offset 0xd8: Missing `C', `D', or `E' at UTF-8 offset 3 in MRSETS record."
2211 AT_SETUP([bad counted string length in mrsets])
2212 AT_KEYWORDS([sack synthetic system file negative multiple response])
2213 AT_DATA([sys-file.sack], [dnl
2215 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2216 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2218 dnl Numeric variable, no label or missing values.
2219 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2221 dnl Multiple response sets.
2222 7; 7; 1; COUNT("$a=Dx");
2227 "be 23d0e2f65c7c5f93bbedcc0f2b260c69" \
2228 "le c3860c1d80e08842264948056e72c0db"
2231 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2233 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2235 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2236 warning: `sys-file.sav' near offset 0xd8: Expecting digit at UTF-8 offset 4 in MRSETS record.
2241 AT_SETUP([missing space in counted string in mrsets])
2242 AT_KEYWORDS([sack synthetic system file negative multiple response])
2243 AT_DATA([sys-file.sack], [dnl
2245 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2246 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2248 dnl Numeric variable, no label or missing values.
2249 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2251 dnl Multiple response sets.
2252 7; 7; 1; COUNT("$a=D1x");
2257 "be c9ce001723763e0698878b7e43a887e8" \
2258 "le e258a1e4491d5a1d1e7d2272ef631a22"
2261 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2263 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2265 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2266 warning: `sys-file.sav' near offset 0xd8: Expecting space at UTF-8 offset 5 in MRSETS record.
2271 AT_SETUP([counted string too long in mrsets])
2272 AT_KEYWORDS([sack synthetic system file negative multiple response])
2273 AT_DATA([sys-file.sack], [dnl
2275 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2276 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2278 dnl Numeric variable, no label or missing values.
2279 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2281 dnl Multiple response sets.
2282 7; 7; 1; COUNT("$a=D4 abc");
2287 "be 196d1266fa0e8e315769dcbe3130e3df" \
2288 "le 23df1ba7b77a26da8ce1c2cfbcaadce0"
2291 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2293 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2295 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2296 warning: `sys-file.sav' near offset 0xd8: 4-byte string starting at UTF-8 offset 6 exceeds record length 9.
2301 AT_SETUP([missing space after counted string in mrsets])
2302 AT_KEYWORDS([sack synthetic system file negative multiple response])
2303 AT_DATA([sys-file.sack], [dnl
2305 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2306 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2308 dnl Numeric variable, no label or missing values.
2309 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2311 dnl Multiple response sets.
2312 7; 7; 1; COUNT("$a=D3 abcx");
2317 "be 86314bb0bbdfad48c10af8b8d8106d6e" \
2318 "le 2b8d05ff501ca78e51f7110ce88a2364"
2321 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2323 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2325 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2326 warning: `sys-file.sav' near offset 0xd8: Expecting space at UTF-8 offset 9 following 3-byte string.
2331 AT_SETUP([missing newline after variable name in mrsets])
2332 AT_KEYWORDS([sack synthetic system file negative multiple response])
2333 AT_DATA([sys-file.sack], [dnl
2335 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2336 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2338 dnl Numeric variable, no label or missing values.
2339 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2341 dnl Multiple response sets.
2342 7; 7; 1; COUNT("$a=C 0 NUM1");
2347 "be cea939cf3e6a5f88cb45e8fa871c5e13" \
2348 "le 52135afec082f50f37eafacadbb2cd65"
2351 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2353 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2355 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2356 warning: `sys-file.sav' near offset 0xd8: Missing new-line parsing variable names at UTF-8 offset 14 in MRSETS record.
2358 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2363 AT_SETUP([duplicate variable name in mrsets])
2364 AT_KEYWORDS([sack synthetic system file negative multiple response])
2365 AT_DATA([sys-file.sack], [dnl
2367 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2368 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2370 dnl Numeric variable, no label or missing values.
2371 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2373 dnl Multiple response sets.
2374 7; 7; 1; COUNT("$a=C 0 NUM1 NUM1"; i8 10);
2379 "be 4b1b5fa2dc22cf0afdd35422290b0a29" \
2380 "le e4304b57976440a036f25f8dd8ac1404"
2383 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2385 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2387 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2388 warning: `sys-file.sav' near offset 0xd8: Duplicate variable name NUM1 at UTF-8 offset 18 in MRSETS record.
2390 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2395 AT_SETUP([mixed variable types in mrsets])
2396 AT_KEYWORDS([sack synthetic system file negative multiple response])
2397 AT_DATA([sys-file.sack], [dnl
2399 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2400 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2403 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2404 2; 8; 0; 0; 0x010800 *2; s8 "STR1";
2406 dnl Multiple response sets.
2407 7; 7; 1; COUNT("$a=C 0 NUM1 STR1"; i8 10);
2412 "be 0f130e967e4097823f85b8711eb20727" \
2413 "le 4dc987b4303fd115f1cae9be3963acc9"
2416 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2418 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2420 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2421 warning: `sys-file.sav' near offset 0xf8: MRSET $a contains both string and numeric variables.
2423 warning: `sys-file.sav' near offset 0xf8: MRSET $a has only 1 variables.
2428 AT_SETUP([missing newline after variable name in mrsets])
2429 AT_KEYWORDS([sack synthetic system file negative multiple response])
2430 AT_DATA([sys-file.sack], [dnl
2432 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2433 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2435 dnl Numeric variable, no label or missing values.
2436 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2438 dnl Multiple response sets.
2439 7; 7; 1; COUNT("$a=C 0 NUM1"; i8 10);
2444 "be 3a891e0a467afb3d622629c70f329ada" \
2445 "le 432998ec08370510411af4f5207c015e"
2448 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2450 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2452 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2453 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2458 AT_SETUP([only one variable in mrset])
2459 AT_KEYWORDS([sack synthetic system file negative multiple response])
2460 AT_DATA([sys-file.sack], [dnl
2462 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2463 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2465 dnl Numeric variable, no label or missing values.
2466 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2468 dnl Multiple response sets.
2469 7; 7; 1; COUNT("$a=C 0 NUM1"; i8 10);
2474 "be 3a891e0a467afb3d622629c70f329ada" \
2475 "le 432998ec08370510411af4f5207c015e"
2478 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2480 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2482 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2483 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2488 AT_SETUP([wrong display parameter size])
2489 AT_KEYWORDS([sack synthetic system file negative])
2490 AT_DATA([sys-file.sack], [dnl
2492 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2493 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2495 dnl Numeric variable, no label or missing values.
2496 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2498 dnl Display parameters record.
2499 7; 11; >>8<<; 2; 1.0; 1.0;
2501 dnl End of dictionary.
2505 "be 7c0f1ae47ae11e37d435c4abaceca226" \
2506 "le c29d05a1f8f15ed2201f31f8b787aaa0"
2509 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2511 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2513 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2514 "warning: `sys-file.sav' near offset 0xd8: Record type 7, subtype 11 has bad size 8 (expected 4)."
2519 AT_SETUP([wrong display parameter count])
2520 AT_KEYWORDS([sack synthetic system file negative])
2521 AT_DATA([sys-file.sack], [dnl
2523 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2524 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2526 dnl Numeric variable, no label or missing values.
2527 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2529 dnl Display parameters record.
2530 7; 11; 4; >>4<<; 1; 1; 2; 2;
2532 dnl End of dictionary.
2536 "be 372b57e73c69b05047b60bf6c596e2a1" \
2537 "le 2a550d8c5ceae4de7ced77df66e49d0f"
2540 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2542 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2544 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2545 warning: `sys-file.sav' near offset 0xd8: Extension 11 has bad count 4 (for 1 variables).
2550 AT_SETUP([wrong display measurement level])
2551 AT_KEYWORDS([sack synthetic system file negative])
2552 AT_DATA([sys-file.sack], [dnl
2554 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2555 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2557 dnl Numeric variable, no label or missing values.
2558 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2560 dnl Display parameters record.
2561 7; 11; 4; 2; >>4<<; 0;
2563 dnl End of dictionary.
2567 "be d43e7616b03743339f37292dec6c2204" \
2568 "le 821533c29a070cefdd8f07f4e1741d2a"
2571 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2573 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2575 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2576 warning: `sys-file.sav' near offset 0xd8: Invalid variable display parameters for variable 0 (NUM1). Default parameters substituted.
2581 AT_SETUP([wrong display alignment])
2582 AT_KEYWORDS([sack synthetic system file negative])
2583 AT_DATA([sys-file.sack], [dnl
2585 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2586 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2588 dnl Numeric variable, no label or missing values.
2589 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2591 dnl Display parameters record.
2592 7; 11; 4; 2; 1; >>-1<<;
2594 dnl End of dictionary.
2598 "be c54bc48b5767e2ec3a9ef31df790cb7c" \
2599 "le a4d8b14af64221abe83adb417d110e10"
2602 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2604 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2606 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2607 warning: `sys-file.sav' near offset 0xd8: Invalid variable display parameters for variable 0 (NUM1). Default parameters substituted.
2612 AT_SETUP([bad variable name in variable/value pair])
2613 AT_KEYWORDS([sack synthetic system file negative])
2614 AT_DATA([sys-file.sack], [dnl
2616 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2617 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2619 dnl Numeric variables.
2620 2; 0; 0; 0; 0x050800 *2; s8 "LONGVARI";
2622 dnl Long variable names.
2623 7; 13; 1; COUNT (>>"xyzzy"<<);
2625 dnl Dictionary termination record.
2629 "be b67b6e3c1900e5a9cc691055008f0447" \
2630 "le 26cc52e601f830f9087a0ea2bd9527df"
2633 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2635 AT_DATA([sys-file.sps], [dnl
2636 GET FILE='sys-file.sav'.
2638 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2639 warning: `sys-file.sav' near offset 0xde: Dictionary record refers to unknown variable xyzzy.
2644 AT_SETUP([duplicate long variable name])
2645 AT_KEYWORDS([sack synthetic system file negative])
2646 AT_DATA([sys-file.sack], [dnl
2648 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2649 2; 4; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2651 dnl Numeric variables.
2652 2; 0; 0; 0; 0x050800 *2; s8 "LONGVARI";
2653 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_A";
2654 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_B";
2655 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_C";
2657 dnl Long variable names.
2659 "LONGVARI=_Invalid"; i8 9;
2660 "LONGVA_A=LongVariableName"; i8 9;
2661 "LONGVA_B=LONGVARIABLENAME"; i8 9;
2664 dnl Dictionary termination record.
2668 "be 9b4b4daa00084d984efb8f889bcb727c" \
2669 "le c1b1470d5cd615106e9ae507c9948d8e"
2672 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2674 AT_DATA([sys-file.sps], [dnl
2675 GET FILE='sys-file.sav'.
2677 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2678 warning: `sys-file.sav' near offset 0x138: Long variable mapping from LONGVARI to invalid variable name `_Invalid'.
2680 warning: `sys-file.sav' near offset 0x138: Duplicate long variable name `LONGVARIABLENAME'.
2685 AT_SETUP([bad very long string length])
2686 AT_KEYWORDS([sack synthetic system file negative])
2687 AT_DATA([sys-file.sack], [dnl
2689 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2690 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2692 dnl Numeric variable.
2693 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2695 dnl Very long string map.
2697 "NUM1=00000"; i8 0; i8 9;
2698 "NUM1=00255"; i8 0; i8 9;
2699 "NUM1=00256"; i8 0; i8 9;
2702 dnl Dictionary termination record.
2706 "be 1309d8d9fb24bcf08952dce9b0f39a94" \
2707 "le 94a39de88f8034001b3e467c4cc04d0f"
2710 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2712 AT_DATA([sys-file.sps], [dnl
2713 GET FILE='sys-file.sav'.
2715 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2716 warning: `sys-file.sav' near offset 0xd8: NUM1 listed as string of invalid length 00000 in very long string record.
2718 "warning: `sys-file.sav' near offset 0xd8: NUM1 listed in very long string record with width 00255, which requires only one segment."
2720 error: `sys-file.sav' near offset 0xd8: Very long string NUM1 overflows dictionary.
2722 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
2727 AT_SETUP([bad very long string segment width])
2728 AT_KEYWORDS([sack synthetic system file negative])
2729 AT_DATA([sys-file.sack], [dnl
2731 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2732 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2735 2; 255; 0; 0; 0x01ff00 *2; s8 "STR1";
2736 (2; -1; 0; 0; 0; 0; s8 "") * 31;
2737 2; >>9<<; 0; 0; 0x010900 *2; s8 "STR1_A";
2738 >>2; -1; 0; 0; 0; 0; s8 "";<<
2740 dnl Very long string map.
2742 "STR1=00256"; i8 0; i8 9;
2745 dnl Dictionary termination record.
2749 "be 1d09a44a46859e6eda28e053dd4b7a8b" \
2750 "le 63b9ac0b3953f3e0d5ee248ebe257794"
2753 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2755 AT_DATA([sys-file.sps], [dnl
2756 GET FILE='sys-file.sav'.
2758 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2759 error: `sys-file.sav' near offset 0x4f8: Very long string with width 256 has segment 1 of width 9 (expected 4).
2761 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
2766 AT_SETUP([too many value labels])
2767 dnl Skip the test if multiplying a small number by INT32_MAX would not
2768 dnl cause an overflow in size_t.
2769 AT_SKIP_IF([test $SIZEOF_SIZE_T -gt 4])
2770 AT_KEYWORDS([sack synthetic system file negative])
2771 AT_DATA([sys-file.sack], [dnl
2773 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2774 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2776 dnl Numeric variable.
2777 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2781 "be 975b2668dde395ddf619977958b37412" \
2782 "le 0c14aa278cfc2a4b801f91c14321f03b"
2785 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2787 AT_DATA([sys-file.sps], [dnl
2788 GET FILE='sys-file.sav'.
2790 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2791 error: `sys-file.sav' near offset 0xd4: Invalid number of labels 2147483647.
2793 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
2798 AT_SETUP([missing type 4 record])
2799 AT_KEYWORDS([sack synthetic system file negative])
2800 AT_DATA([sys-file.sack], [dnl
2802 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2803 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2805 dnl Numeric variable.
2806 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2808 dnl Value label with missing type 4 record.
2809 3; 1; 1.0; i8 3; s7 "one";
2811 dnl End of dictionary.
2815 "be 5e1286ac92e3f25ff98492bc5019d608" \
2816 "le b33c12f776bbcaa43aa3bfdd4799e0c0"
2819 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2821 AT_DATA([sys-file.sps], [dnl
2822 GET FILE='sys-file.sav'.
2824 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2825 error: `sys-file.sav' near offset 0xe8: Variable index record (type 4) does not immediately follow value label record (type 3) as it should.
2827 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
2832 AT_SETUP([value label with no associated variables])
2833 AT_KEYWORDS([sack synthetic system file negative])
2834 AT_DATA([sys-file.sack], [dnl
2836 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2837 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2839 dnl Numeric variable.
2840 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2842 dnl Value label with no variables.
2843 3; 1; 1.0; i8 3; s7 "one"; 4; >>0<<;
2846 "be b0dcec30a936cbcad21c4f3d6fe10fcf" \
2847 "le 3b9fdfce5c8c248048232fd6eac018e3"
2850 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2852 AT_DATA([sys-file.sps], [dnl
2853 GET FILE='sys-file.sav'.
2855 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2856 error: `sys-file.sav' near offset 0xec: Number of variables associated with a value label (0) is not between 1 and the number of variables (1).
2858 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
2863 AT_SETUP([type 4 record names long string variable])
2864 AT_KEYWORDS([sack synthetic system file negative])
2865 AT_DATA([sys-file.sack], [dnl
2867 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2868 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2870 dnl Long string variable.
2871 2; 9; 0; 0; 0x010900 *2; s8 "STR1";
2872 2; -1; 0; 0; 0; 0; s8 "";
2874 dnl Value label that names long string variable.
2875 3; 1; s8 "xyzzy"; i8 3; s7 "one"; 4; 1; >>1<<;
2877 dnl End of dictionary.
2881 "be 14053a4f09de4c7c4c55281534dd66f4" \
2882 "le 8a61cc994c659fd66307d2f0fd64ce20"
2885 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
2886 AT_DATA([sys-file.sps], [dnl
2887 GET FILE='sys-file.sav'.
2889 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2890 error: `sys-file.sav' near offset 0xf4: Value labels may not be added to long string variables (e.g. STR1) using records types 3 and 4.
2892 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
2897 AT_SETUP([variables for value label must all be same type])
2898 AT_KEYWORDS([sack synthetic system file negative])
2899 AT_DATA([sys-file.sack], [dnl
2901 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2902 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2905 2; 6; 0; 0; 0x010600 *2; s8 "STR1";
2906 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2908 dnl Value label that names numeric and string variables.
2909 3; 1; s8 "xyzzy"; i8 3; s7 "one"; 4; 2; >>1; 2<<;
2911 dnl End of dictionary.
2915 "be 7577c456726a88f52bbef63a8b47bf1a" \
2916 "le 3ba5c6af9ad0ae5cc88f9f63e726e414"
2919 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
2920 AT_DATA([sys-file.sps], [dnl
2921 GET FILE='sys-file.sav'.
2923 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2924 "error: `sys-file.sav' near offset 0xf4: Variables associated with value label are not all of identical type. Variable STR1 is string, but variable NUM1 is numeric."
2926 sys-file.sps:1: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
2931 AT_SETUP([duplicate value labels type])
2932 AT_KEYWORDS([sack synthetic system file negative])
2933 AT_DATA([sys-file.sack], [dnl
2935 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2936 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2939 2; 6; 0; 0; 0x010600 *2; s8 "STR1";
2940 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2942 dnl Duplicate value labels.
2943 3; 1; s8 "xyzzy"; i8 3; s7 "one"; 4; 2; >>1; 1<<;
2944 3; 1; 1.0; i8 3; s7 "one"; 4; 2; >>2; 2<<;
2946 dnl End of dictionary.
2950 "be ef0f5b2ebddb5a3bfcda16c93a2508f4" \
2951 "le c00e27abd9a6c06bf29a108d7220435a"
2954 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2956 AT_DATA([sys-file.sps], [dnl
2957 GET FILE='sys-file.sav'.
2959 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2960 warning: `sys-file.sav' near offset 0xf4: Duplicate value label for `xyzzy ' on STR1.
2962 warning: `sys-file.sav' near offset 0x11c: Duplicate value label for 1 on NUM1.
2967 AT_SETUP([missing attribute value])
2968 AT_KEYWORDS([sack synthetic system file negative])
2969 AT_DATA([sys-file.sack], [dnl
2971 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2972 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2975 2; 0; 0; 0; 0x050800 *2; s8 "FIRSTVAR";
2977 dnl Data file attributes record.
2982 dnl Variable attributes record.
2988 dnl Dictionary termination record.
2992 "be 0fc71f5e3cdb6b7f2dd73d011d4885c2" \
2993 "le e519b44715400156a2bfe648eb5cff34"
2996 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2998 AT_DATA([sys-file.sps], [dnl
2999 GET FILE='sys-file.sav'.
3001 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3002 warning: `sys-file.sav' near offset 0xdf: Error parsing attribute value Attr1[[1]].
3004 warning: `sys-file.sav' near offset 0x102: Error parsing attribute value fred[[2]].
3009 AT_SETUP([unquoted attribute value])
3010 AT_KEYWORDS([sack synthetic system file negative])
3011 AT_DATA([sys-file.sack], [dnl
3013 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3014 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3017 2; 0; 0; 0; 0x050800 *2; s8 "FIRSTVAR";
3019 dnl Data file attributes record.
3021 "Attr1(value"; i8 10;
3025 dnl Variable attributes record.
3028 "fred(23"; i8 10; ")"
3031 dnl Dictionary termination record.
3035 "be 33dba37c2247e63c04bb74a7b472293d" \
3036 "le 041025a9d9d9e21a7fabd90ba7341934"
3039 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3041 AT_DATA([sys-file.sps], [dnl
3042 GET FILE='sys-file.sav'.
3044 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3045 warning: `sys-file.sav' near offset 0xe4: Attribute value Attr1[[1]] is not quoted: value.
3047 warning: `sys-file.sav' near offset 0x106: Attribute value fred[[1]] is not quoted: 23.
3052 AT_SETUP([bad variable name in long string value label])
3053 AT_KEYWORDS([sack synthetic system file negative])
3054 AT_DATA([sys-file.sack], [dnl
3056 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3057 2; 3; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3060 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3061 2; 14; 0; 0; 0x010e00 *2; s8 "STR14";
3062 2; -1; 0; 0; 0; 0; s8 "";
3065 dnl No variable named STR9.
3066 COUNT(>>"STR9"<<); 9;
3067 1; COUNT("RSTUVWXYZ"); COUNT("value label for `RSTUVWXYZ'");
3069 dnl NUM1 is numeric.
3070 COUNT(>>"NUM1"<<); 0;
3071 1; COUNT("xyz"); COUNT("value label for 1.0");
3073 dnl Wrong width for STR14.
3074 COUNT("STR14"); >>9<<;
3075 1; COUNT("RSTUVWXYZ"); COUNT("value label for `RSTUVWXYZ'");
3077 dnl Wrong width for value.
3079 1; COUNT(>>"RSTUVWXYZ"<<); COUNT("value label for `RSTUVWXYZ'");
3081 dnl Duplicate value label.
3082 COUNT("STR14"); 14; 2;
3083 COUNT("abcdefghijklmn"); COUNT("value label for `abcdefghijklmn'");
3084 >>COUNT("abcdefghijklmn"); COUNT("another value label for `abcdefghijklmn'")<<;
3087 dnl Dictionary termination record.
3091 "be cf2e883dadb00e2c6404c09ea0a4e388" \
3092 "le 89c340faf0a7e4a8c834f9687684c091"
3095 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3097 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3099 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3100 warning: `sys-file.sav' near offset 0x128: Ignoring long string value record for unknown variable STR9.
3102 warning: `sys-file.sav' near offset 0x164: Ignoring long string value record for numeric variable NUM1.
3104 warning: `sys-file.sav' near offset 0x193: Ignoring long string value record for variable STR14 because the record's width (9) does not match the variable's width (14).
3106 "warning: `sys-file.sav' near offset 0x1d4: Ignoring long string value 0 for variable str14, with width 14, that has bad value width 9."
3108 warning: `sys-file.sav' near offset 0x259: Duplicate value label for `abcdefghijklmn' on str14.
3113 AT_SETUP([fewer data records than indicated by file header])
3114 AT_KEYWORDS([sack synthetic system file negative])
3115 AT_DATA([sys-file.sack], [dnl
3117 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3118 2; 2; 0; 0; >>5<<; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3120 dnl Numeric variables.
3121 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3122 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
3130 dnl Missing record here.
3133 "be 6ee097c3934055d0c4564641636f4b5a" \
3134 "le ae03fe1b888091d6938b5a436d44ac60"
3137 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3139 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3142 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3143 [error: Error reading case from file `sys-file.sav'.
3152 sys-file.sps:2: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
3157 AT_SETUP([partial data record between variables])
3158 AT_KEYWORDS([sack synthetic system file negative])
3159 AT_DATA([sys-file.sack], [dnl
3161 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3162 2; 2; 0; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3164 dnl Numeric variables.
3165 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3166 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
3174 "be 4bcc085d7d8f0f09c6a4ba8064ffe61c" \
3175 "le 7387fc5edd2740aff92c30ca688d6d9b"
3178 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3180 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3183 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3184 [error: `sys-file.sav' near offset 0x110: File ends in partial case.
3190 sys-file.sps:2: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
3195 AT_SETUP([partial data record within long string])
3196 AT_KEYWORDS([sack synthetic system file negative])
3197 AT_DATA([sys-file.sack], [dnl
3199 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3200 2; 2; 0; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3202 dnl Numeric variables.
3203 2; 14; 0; 0; 0x010e00 *2; s8 "STR14";
3204 2; -1; 0; 0; 0; 0; s8 "";
3208 s14 "one data item";
3212 "be 4a9e84f9e679afb7bb71acd0bb7eab89" \
3213 "le 30752606f14ee2deec2854e8e6de4b3b"
3216 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3218 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3221 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3222 [error: `sys-file.sav' near offset 0x10e: Unexpected end of file.
3228 sys-file.sps:2: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.
3233 AT_SETUP([partial compressed data record])
3234 AT_KEYWORDS([sack synthetic system file positive])
3235 AT_DATA([sys-file.sack], [dnl
3237 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3239 6; dnl Nominal case size
3242 -1; dnl Unspecified number of cases.
3244 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
3247 dnl Numeric variables.
3248 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3249 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
3251 dnl String variable.
3252 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
3253 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
3254 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
3255 2; -1; 0; 0; 0; 0; s8 "";
3257 dnl Dictionary termination record.
3260 dnl Compressed data.
3261 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
3264 "be ef01b16e2e397d979a3a7d20725ebe6d" \
3265 "le 51f7a61e9bc68992469d16c55d6ecd88"
3268 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3270 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3273 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3274 [error: `sys-file.sav' near offset 0x190: File ends in partial case.
3277 num1,num2,str4,str8,str15
3278 -99,0,,abcdefgh,0123 @&t@
3280 sys-file.sps:2: error: Stopping syntax file processing here to avoid a cascade of dependent command failures.