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 28; dnl Nominal case size
14 "01 Jan 11"; "20:53:52";
15 "PSPP synthetic test file: "; i8 244; i8 245; i8 246; i8 248; s34 "";
18 dnl Numeric variable, no label or missing values.
19 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
21 dnl Numeric variable, variable label.
22 2; 0; 1; 0; 0x050800 *2; s8 "NUM2";
23 32; "Numeric variable 2's label ("; i8 249; i8 250; i8 251; ")";
25 dnl Numeric variable, one missing value.
26 2; 0; 0; 1; 0x050800 *2; s8 "NUM3";
29 dnl Numeric variable, variable label and missing value.
30 2; 0; 1; 1; 0x050800 *2; s8 "NUM4";
31 30; "Another numeric variable label"; i8 0 * 2;
34 dnl Numeric variable, two missing values.
35 2; 0; 0; 2; 0x050800 *2; s8 "NUM5"; 1.0; 2.0;
37 dnl Numeric variable, three missing values.
38 2; 0; 0; 3; 0x050800 *2; s8 "NUM6"; 1.0; 2.0; 3.0;
40 dnl Numeric variable, range of missing values.
41 2; 0; 0; -2; 0x050800 *2; s8 "NUM7"; 1.0; 3.0;
43 dnl Numeric variables, range of missing values plus discrete value.
44 2; 0; 0; -3; 0x050800 *2; s8 "NUM8"; 1.0; 3.0; 5.0;
45 2; 0; 0; -3; 0x050800 *2; s8 "NUM9"; 1.0; HIGHEST; -5.0;
46 2; 0; 0; -3; 0x050800 *2; "NUM"; i8 192; i8 200; i8 204; i8 209; i8 210;
49 dnl String variable, no label or missing values.
50 2; 4; 0; 0; 0x010400 *2; s8 "STR1";
52 dnl String variable, variable label.
53 2; 4; 1; 0; 0x010400 *2; s8 "STR2";
54 25; "String variable 2's label"; i8 0 * 3;
56 dnl String variable, one missing value.
57 2; 4; 0; 1; 0x010400 *2; s8 "STR3"; s8 "MISS";
59 dnl String variable, variable label and missing value.
60 2; 4; 1; 1; 0x010400 *2; s8 "STR4";
61 29; "Another string variable label"; i8 0 * 3;
64 dnl String variable, two missing values.
65 2; 4; 0; 2; 0x010400 *2; s8 "STR5"; s8 "MISS"; s8 "OTHR";
67 dnl String variable, three missing values.
68 2; 4; 0; 3; 0x010400 *2; s8 "STR6"; s8 "MISS"; s8 "OTHR"; s8 "MORE";
70 dnl Long string variable, one missing value.
71 dnl (This is not how SPSS represents missing values for long strings--it
72 dnl uses a separate record as shown later below--but old versions of PSPP
73 dnl did use this representation so we continue supporting it for backward
75 2; 11; 0; 1; 0x010b00 *2; s8 "STR7"; "first8by";
76 2; -1; 0; 0; 0; 0; s8 "";
78 dnl Long string variables that will have missing values added with a
80 2; 9; 0; 0; 0x010900 *2; s8 "STR8";
81 2; -1; 0; 0; 0; 0; s8 "";
82 2; 10; 0; 0; 0x010a00 *2; s8 "STR9";
83 2; -1; 0; 0; 0; 0; s8 "";
84 2; 11; 0; 0; 0x010b00 *2; s8 "STR10";
85 2; -1; 0; 0; 0; 0; s8 "";
87 dnl Long string variable, value label.
88 2; 25; 1; 0; 0x011900 *2; s8 "STR11"; 14; "25-byte string"; i8 0 * 2;
89 ( 2; -1; 0; 0; 0; 0; s8 ""; ) * 2;
90 dnl Variable label fields on continuation records have been spotted in system
91 dnl files created by "SPSS Power Macintosh Release 6.1".
92 2; -1; 1; 0; 0; 0; s8 ""; 20; "dummy variable label";
94 dnl Machine integer info record.
95 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
97 dnl Machine floating-point info record.
98 7; 4; 8; 3; SYSMIS; HIGHEST; LOWEST;
100 dnl Long string variable missing values record.
102 dnl One missing value for STR8.
103 COUNT("STR8"); i8 1; 8; "abcdefgh";
105 dnl Two missing values for STR9.
106 COUNT("STR9"); i8 2; 8; "abcdefgh"; 8; "01234567";
108 dnl Three missing values for STR9.
109 COUNT("STR10"); i8 3; 8; "abcdefgh"; 8; "01234567"; 8; "0 ";
112 dnl Character encoding record.
113 7; 20; 1; 12; "windows-1252";
115 dnl Dictionary termination record.
119 1.0; 2.0; 3.0; 4.0; 5.0; 6.0; 7.0; 8.0; 9.0; 10.0;
120 s8 "abcd"; s8 "efgh"; s8 "ijkl"; s8 "mnop"; s8 "qrst"; s8 "uvwx";
121 s16 "yzABCDEFGHI"; s16 "JKLMNOPQR"; s16 "STUVWXYZ01";
122 s16 "23456789abc"; s32 "defghijklmnopqstuvwxyzABC";
125 "be ae072375af73d628a544cc2230dd72c9" \
126 "le 039a21ab64f68c65b240e782a6b0f563"
129 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
131 AT_DATA([sys-file.sps], [dnl
132 GET FILE='sys-file.sav'.
137 AT_CHECK([pspp -o pspp.csv sys-file.sps])
138 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
139 File label: PSPP synthetic test file: ôõöø
141 Variable,Description,,Position
143 num2,Label: Numeric variable 2's label (ùúû),,2
147 num4,Label: Another numeric variable label,,4
151 ,Missing Values: 1; 2,,
153 ,Missing Values: 1; 2; 3,,
155 ,Missing Values: 1 THRU 3,,
157 ,Missing Values: 1 THRU 3; 5,,
159 ,Missing Values: 1 THRU HIGHEST; -5,,
160 numàèìñò,Format: F8.0,,10
161 ,Missing Values: LOWEST THRU 1; 5,,
163 str2,Label: String variable 2's label,,12
166 ,"Missing Values: ""MISS""",,
167 str4,Label: Another string variable label,,14
169 ,"Missing Values: ""OTHR""",,
171 ,"Missing Values: ""MISS""; ""OTHR""",,
173 ,"Missing Values: ""MISS""; ""OTHR""; ""MORE""",,
175 ,"Missing Values: ""first8by""",,
177 ,"Missing Values: ""abcdefgh""",,
179 ,"Missing Values: ""abcdefgh""; ""01234567""",,
180 str10,Format: A11,,20
181 ,"Missing Values: ""abcdefgh""; ""01234567""; ""0 """,,
182 str11,Label: 25-byte string,,21
186 num1,num2,num3,num4,num5,num6,num7,num8,num9,numàèìñò,str1,str2,str3,str4,str5,str6,str7,str8,str9,str10,str11
187 1,2,3,4,5,6,7,8,9,10,abcd,efgh,ijkl,mnop,qrst,uvwx,yzABCDEFGHI,JKLMNOPQR,STUVWXYZ01,23456789abc,defghijklmnopqstuvwxyzABC
192 AT_SETUP([unspecified number of variable positions])
193 AT_KEYWORDS([sack synthetic system file positive])
194 AT_DATA([sys-file.sack], [dnl
196 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
198 -1; dnl Nominal case size (unspecified)
199 0; dnl Not compressed
203 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
206 dnl Numeric variable, no label or missing values.
207 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
209 dnl Numeric variable, variable label.
210 2; 0; 1; 0; 0x050800 *2; s8 "NUM2";
211 26; "Numeric variable 2's label"; i8 0 *2;
213 dnl Dictionary termination record.
220 "be 413e7bc80a47fcd7e4c8020e8e120060" \
221 "le d7db9120b1ff28c83aa6fe9fc405d903"
224 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
226 AT_DATA([sys-file.sps], [dnl
227 GET FILE='sys-file.sav'.
231 AT_CHECK([pspp -o pspp.csv sys-file.sps])
232 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
233 Variable,Description,,Position
235 num2,Label: Numeric variable 2's label,,2
245 AT_SETUP([wrong number of variable positions but version 13])
246 AT_KEYWORDS([sack synthetic system file positive])
247 AT_DATA([sys-file.sack], [dnl
249 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
251 -1; dnl Nominal case size (unspecified)
252 0; dnl Not compressed
256 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
259 dnl Numeric variable, no label or missing values.
260 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
262 dnl Numeric variable, variable label.
263 2; 0; 1; 0; 0x050800 *2; s8 "NUM2";
264 26; "Numeric variable 2's label"; i8 0 *2;
266 dnl Machine integer info record (SPSS 13).
267 7; 3; 4; 8; 13; 2; 3; -1; 1; 1; ENDIAN; 1252;
269 dnl Dictionary termination record.
276 "be 3d17aae7d99538dc73c5cb42692b1038" \
277 "le 8ad1000df598617d5258f323c882d749"
280 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
282 AT_DATA([sys-file.sps], [dnl
283 GET FILE='sys-file.sav'.
287 AT_CHECK([pspp -o pspp.csv sys-file.sps])
288 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
289 Variable,Description,,Position
291 num2,Label: Numeric variable 2's label,,2
301 AT_SETUP([value labels])
302 AT_KEYWORDS([sack synthetic system file positive])
303 AT_DATA([sys-file.sack], [dnl
305 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
307 22; dnl Nominal case size
308 0; dnl Not compressed
312 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
315 dnl Numeric variables.
316 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
317 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
318 2; 0; 0; 0; 0x050800 *2; s8 "NUM3";
319 2; 0; 0; 0; 0x050800 *2; s8 "NUM4";
320 2; 0; 0; 0; 0x050800 *2; s8 "NUM5";
322 dnl String variables.
323 2; 1; 0; 0; 0x010100 *2; s8 "STR1"; dnl index 6
324 2; 2; 0; 0; 0x010200 *2; s8 "STR2"; dnl index 7
325 2; 3; 0; 0; 0x010300 *2; s8 "STR3"; dnl index 8
326 2; 4; 0; 0; 0x010400 *2; s8 "STR4"; dnl index 9
327 2; 4; 0; 0; 0x010400 *2; s8 "STR5"; dnl index 10
328 2; 6; 0; 0; 0x010600 *2; s8 "STR6"; dnl index 11
329 2; 7; 0; 0; 0x010700 *2; s8 "STR7"; dnl index 12
330 2; 8; 0; 0; 0x010800 *2; s8 "STR8"; dnl index 13
331 2; 9; 0; 0; 0x010900 *2; "STR9"; i8 230; s3 ""; dnl index 14
332 2; -1; 0; 0; 0; 0; s8 "";
333 2; 12; 0; 0; 0x010c00 *2; s8 "STR12"; dnl index 16
334 2; -1; 0; 0; 0; 0; s8 "";
335 2; 16; 0; 0; 0x011000 *2; s8 "STR16"; dnl index 18
336 2; -1; 0; 0; 0; 0; s8 "";
337 2; 17; 0; 0; 0x011100 *2; s8 "STR17"; dnl index 20
338 ( 2; -1; 0; 0; 0; 0; s8 ""; ) * 2;
340 dnl One value label for NUM1.
341 3; 1; 1.0; i8 17; i8 238; i8 228; i8 232; i8 237; s19 " (in Russian)"; 4; 1; 1;
343 dnl Two value labels for NUM2, as a single pair of type 3 and type 4 records.
344 3; 2; 1.0; i8 3; s7 "one"; 2.0; i8 3; s7 "two"; 4; 1; 2;
346 dnl Two value labels for NUM3, as two pairs of type 3 and type 4 records.
347 3; 1; 3.0; i8 5; s7 "three"; 4; 1; 3;
348 3; 1; 4.0; i8 4; s7 "four"; 4; 1; 3;
350 dnl Two common value labels for NUM4 and NUM5, plus two different ones for each.
351 3; 1; 5.0; i8 4; s7 "five"; 4; 1; 4;
352 3; 1; 6.0; i8 3; s7 "six"; 4; 1; 5;
353 3; 2; 7.0; i8 5; s7 "seven"; 8.0; i8 5; s7 "eight"; 4; 2; 4; 5;
354 3; 1; 9.0; i8 4; s7 "nine"; 4; 1; 4;
355 3; 1; 10.0; i8 3; s7 "ten"; 4; 1; 5;
357 dnl One value label for STR1.
358 3; 1; s8 "a"; i8 19; s23 "value label for `a'"; 4; 1; 6;
360 dnl Two value labels for STR2, as a single pair of type 3 and type 4 records.
362 s8 "bc"; i8 20; s23 "value label for `bc'";
363 s8 "de"; i8 20; s23 "value label for `de'";
366 dnl Two value labels for STR3, as two pairs of type 3 and type 4 records.
367 3; 1; s8 "fgh"; i8 21; s23 "value label for `fgh'"; 4; 1; 8;
368 3; 1; s8 "ijk"; i8 21; s23 "value label for `ijk'"; 4; 1; 8;
370 dnl Two common value labels for STR4 and STR5, plus two different ones for each.
371 3; 1; s8 "lmno"; i8 22; s23 "value label for `lmno'"; 4; 1; 9;
372 3; 1; s8 "pqrs"; i8 22; s23 "value label for `pqrs'"; 4; 1; 10;
374 s8 "tuvw"; i8 22; s23 "value label for `tuvw'";
375 s8 "xyzA"; i8 22; s23 "value label for `xyzA'";
377 3; 1; s8 "BCDE"; i8 22; s23 "value label for `BCDE'"; 4; 1; 9;
378 3; 1; s8 "FGHI"; i8 22; s23 "value label for `FGHI'"; 4; 1; 10;
380 dnl One value label for STR6, STR7, STR8.
381 3; 1; s8 "JKLMNO"; i8 24; s31 "value label for `JKLMNO'"; 4; 1; 11;
382 3; 1; s8 "JKLMNOP"; i8 25; s31 "value label for `JKLMNOP'"; 4; 1; 12;
383 3; 1; s8 "JKLMNOPQ"; i8 26; s31 "value label for `JKLMNOPQ'"; 4; 1; 13;
385 dnl Machine integer info record.
386 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1251;
388 dnl Character encoding record.
389 7; 20; 1; 12; "windows-1251";
392 dnl One value label for STR9ж,
393 COUNT("STR9"; i8 230); 9; 1; COUNT("RSTUVWXYZ"); COUNT("value label for `RSTUVWXYZ'");
395 dnl Two value labels for STR12.
396 COUNT("STR12"); 12; 2;
397 COUNT("0123456789ab"); COUNT("value label for `0123456789ab'");
398 COUNT("cdefghijklmn"); COUNT("value label for `cdefghijklmn'");
400 dnl Three value labels for STR16.
401 COUNT("STR16"); 16; 3;
402 COUNT("opqrstuvwxyzABCD"); COUNT("value label for `opqrstuvwxyzABCD'");
403 COUNT("EFGHIJKLMNOPQRST"); COUNT("value label for `EFGHIJKLMNOPQRST'");
404 COUNT("UVWXYZ0123456789"); COUNT("value label for `UVWXYZ0123456789' with Cyrillic letters: `"; i8 244; i8 245; i8 246; "'");
406 dnl One value label for STR17.
407 COUNT("STR17"); 17; 1;
408 COUNT("abcdefghijklmnopq"); COUNT("value label for `abcdefghijklmnopq'");
411 dnl Dictionary termination record.
415 "be b27d766d8a5ad9e901c8b244591a5942" \
416 "le eb2e93f3cc29acd605b80e6c3af25ba6"
419 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
421 AT_DATA([sys-file.sps], [dnl
422 GET FILE='sys-file.sav'.
425 AT_CHECK([pspp -o pspp.csv sys-file.sps])
426 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
427 Variable,Description,,Position
429 ,1,один (in Russian),
447 ,a,value label for `a',
449 ,bc,value label for `bc',
450 ,de,value label for `de',
452 ,fgh,value label for `fgh',
453 ,ijk,value label for `ijk',
455 ,BCDE,value label for `BCDE',
456 ,lmno,value label for `lmno',
457 ,tuvw,value label for `tuvw',
458 ,xyzA,value label for `xyzA',
460 ,FGHI,value label for `FGHI',
461 ,pqrs,value label for `pqrs',
462 ,tuvw,value label for `tuvw',
463 ,xyzA,value label for `xyzA',
465 ,JKLMNO,value label for `JKLMNO',
467 ,JKLMNOP,value label for `JKLMNOP',
469 ,JKLMNOPQ,value label for `JKLMNOPQ',
471 ,RSTUVWXYZ,value label for `RSTUVWXYZ',
472 str12,Format: A12,,15
473 ,0123456789ab,value label for `0123456789ab',
474 ,cdefghijklmn,value label for `cdefghijklmn',
475 str16,Format: A16,,16
476 ,EFGHIJKLMNOPQRST,value label for `EFGHIJKLMNOPQRST',
477 ,UVWXYZ0123456789,value label for `UVWXYZ0123456789' with Cyrillic letters: `фхц',
478 ,opqrstuvwxyzABCD,value label for `opqrstuvwxyzABCD',
479 str17,Format: A17,,17
480 ,abcdefghijklmnopq,value label for `abcdefghijklmnopq',
485 AT_SETUP([documents])
486 AT_KEYWORDS([sack synthetic system file positive])
487 AT_DATA([sys-file.sack], [dnl
489 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
491 1; dnl Nominal case size
492 0; dnl Not compressed
496 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
499 dnl Numeric variable, no label or missing values.
500 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
502 dnl Machine integer info record.
503 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
507 s80 "First line of documents";
508 s80 "Second line of documents";
509 "abb"; i8 233; " appliqu"; i8 233; " attach"; i8 233; " blas"; i8 233; " caf"; i8 233; " canap"; i8 233; " clich"; i8 233; " consomm"; i8 233;
512 s80 "Last line of documents";
514 dnl Character encoding record.
515 7; 20; 1; 12; "windows-1252";
517 dnl Dictionary termination record.
524 "be 3555f74f3e714a3a703de7df56ce6d24" \
525 "le ede5a0f805a1aab096ea86abf677ff34"
528 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
530 AT_DATA([sys-file.sps], [dnl
531 GET FILE='sys-file.sav'.
535 AT_CHECK([pspp -o pspp.csv sys-file.sps])
536 AT_CHECK([cat pspp.csv], [0], [dnl
537 Documents in the active dataset:
539 First line of documents
541 Second line of documents
543 abbé appliqué attaché blasé café canapé cliché consommé
547 Last line of documents
556 AT_SETUP([multiple response sets])
557 AT_KEYWORDS([sack synthetic system file positive])
558 AT_DATA([sys-file.sack], [dnl
560 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
562 16; dnl Nominal case size
563 0; dnl Not compressed
567 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
571 2; 0; 0; 0; 0x050800 *2; i8 0x82; i8 0xa0; s6 "";
572 2; 0; 0; 0; 0x050800 *2; s8 "B";
573 2; 0; 0; 0; 0x050800 *2; s8 "C";
576 2; 0; 0; 0; 0x050800 *2; s8 "D";
577 2; 0; 0; 0; 0x050800 *2; s8 "E";
578 2; 0; 0; 0; 0x050800 *2; s8 "F";
579 2; 0; 0; 0; 0x050800 *2; s8 "G";
582 2; 4; 0; 0; 0x010400 *2; s8 "H";
583 2; 4; 0; 0; 0x010400 *2; s8 "I";
584 2; 4; 0; 0; 0x010400 *2; s8 "J";
587 2; 0; 0; 0; 0x050800 *2; s8 "K";
588 2; 0; 0; 0; 0x050800 *2; s8 "L";
589 2; 0; 0; 0; 0x050800 *2; s8 "M";
592 2; 6; 0; 0; 0x010600 *2; s8 "N";
593 2; 6; 0; 0; 0x010600 *2; s8 "O";
594 2; 6; 0; 0; 0x010600 *2; s8 "P";
596 dnl Machine integer info record.
597 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 932;
601 "$a=C 10 my mcgroup "; i8 0x82; i8 0xa0; " b c"; i8 10;
602 "$b=D2 55 0 g e f d"; i8 10;
603 "$c=D4 "; i8 0x82; i8 0xcd; i8 0x82; i8 0xa2; " 10 mdgroup #2 h i j"; i8 10);
607 "$d=E 1 2 34 13 third mdgroup k l m"; i8 10;
608 "$e=E 11 6 choice 0 n o p"; i8 10);
610 dnl Character encoding record.
611 7; 20; 1; 9; "shift_jis";
613 dnl Dictionary termination record.
617 "be fdf260a05220e08c748967dcb90d8b15" \
618 "le 4c9b0c0636bc0aa0cc16684c8188d1c7"
621 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
623 AT_DATA([sys-file.sps], [dnl
624 GET FILE='sys-file.sav'.
625 MRSETS /DISPLAY NAME=ALL.
627 AT_CHECK([pspp -o pspp.csv sys-file.sps])
628 AT_CHECK([cat pspp.csv], [0], [dnl
629 Table: Multiple Response Sets
630 Name,Variables,Details
634 ","Multiple category set
641 ","Multiple dichotomy set
643 Category label source: Variable labels
648 ","Multiple dichotomy set
650 Label source: Provided by user
652 Category label source: Variable labels
657 ","Multiple dichotomy set
659 Label source: Provided by user
661 Category label source: Value labels of counted value
666 ","Multiple dichotomy set
667 Label source: First variable label among variables
668 Counted value: `choice'
669 Category label source: Value labels of counted value
675 dnl Also checks for handling of CR-only line ends in file label and
676 dnl extra product info.
677 AT_SETUP([extra product info])
678 AT_KEYWORDS([sack synthetic system file positive])
679 AT_DATA([sys-file.sack], [dnl
681 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
683 4; dnl Nominal case size
684 0; dnl Not compressed
688 "01 Jan 11"; "20:53:52"; "PSPP synthetic"; i8 13; s49 "test file";
691 dnl Numeric variables.
692 2; 0; 0; 0; 0x050800 *2; s8 "A";
693 2; 0; 0; 0; 0x050800 *2; s8 "B";
694 2; 0; 0; 0; 0x050800 *2; s8 "C";
695 2; 0; 0; 0; 0x050800 *2; s8 "D";
697 dnl Extra product info.
698 7; 10; 1; COUNT ("Extra product info"; i8 13; "another line"; i8 13; "blah");
700 dnl Dictionary termination record.
704 "be 0e1cac77501322b012637dcaeb3858ab" \
705 "le ecffd25cae41bbc89c29487abe192016"
708 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
710 AT_DATA([sys-file.sps], [dnl
711 SYSFILE INFO FILE='sys-file.sav'.
713 AT_CHECK([pspp -o pspp.csv sys-file.sps])
714 AT_CHECK([sed 7q pspp.csv], [0], [dnl
716 Label:,"PSPP synthetic
718 Created:,01 Jan 11 20:53:52 by $(@%:@) SPSS DATA FILE PSPP synthetic test file
719 Product:,"Extra product info
726 AT_SETUP([variable display parameters, without width])
727 AT_KEYWORDS([sack synthetic system file positive])
728 AT_DATA([sys-file.sack], [dnl
730 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
732 19; dnl Nominal case size
733 0; dnl Not compressed
737 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
740 dnl Numeric variables.
741 2; 0; 0; 0; 0x050800 *2; s8 "A";
742 2; 0; 0; 0; 0x050800 *2; s8 "B";
743 2; 0; 0; 0; 0x050800 *2; s8 "C";
744 2; 0; 0; 0; 0x050800 *2; s8 "D";
746 dnl Short string variables.
747 2; 3; 0; 0; 0x010300 *2; s8 "H";
748 2; 3; 0; 0; 0x010300 *2; s8 "I";
749 2; 3; 0; 0; 0x010300 *2; s8 "J";
750 2; 3; 0; 0; 0x010300 *2; s8 "K";
752 dnl Long string variables.
753 2; 9; 0; 0; 0x010900 *2; s8 "L";
754 2; -1; 0; 0; 0; 0; s8 "";
755 2; 10; 0; 0; 0x010a00 *2; s8 "M";
756 2; -1; 0; 0; 0; 0; s8 "";
757 2; 17; 0; 0; 0x011100 *2; s8 "N";
758 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 2;
759 2; 25; 0; 0; 0x011900 *2; s8 "O";
760 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 3;
762 dnl Variable display parameters
777 dnl Dictionary termination record.
781 "be c130d9345080579b8862b360924edbfa" \
782 "le 6fde96f5a7c7386bff6cca049cd84d6a"
785 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
787 AT_DATA([sys-file.sps], [dnl
788 GET FILE='sys-file.sav'.
791 AT_CHECK([pspp -o pspp.csv sys-file.sps])
792 AT_CHECK([cat pspp.csv], [0], [dnl
793 Variable,Description,,Position
796 ,Display Alignment: Left,,
800 ,Display Alignment: Left,,
804 ,Display Alignment: Left,,
808 ,Display Alignment: Right,,
812 ,Display Alignment: Right,,
816 ,Display Alignment: Right,,
820 ,Display Alignment: Center,,
824 ,Display Alignment: Center,,
828 ,Display Alignment: Center,,
832 ,Display Alignment: Left,,
836 ,Display Alignment: Right,,
840 ,Display Alignment: Center,,
846 AT_SETUP([variable display parameters, with width])
847 AT_KEYWORDS([sack synthetic system file positive])
848 AT_DATA([sys-file.sack], [dnl
850 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
852 19; dnl Nominal case size
853 0; dnl Not compressed
857 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
860 dnl Numeric variables.
861 2; 0; 0; 0; 0x050800 *2; s8 "A";
862 2; 0; 0; 0; 0x050800 *2; s8 "B";
863 2; 0; 0; 0; 0x050800 *2; s8 "C";
864 2; 0; 0; 0; 0x050800 *2; s8 "D";
866 dnl Short string variables.
867 2; 3; 0; 0; 0x010300 *2; s8 "H";
868 2; 3; 0; 0; 0x010300 *2; s8 "I";
869 2; 3; 0; 0; 0x010300 *2; s8 "J";
870 2; 3; 0; 0; 0x010300 *2; s8 "K";
872 dnl Long string variables.
873 2; 9; 0; 0; 0x010900 *2; s8 "L";
874 2; -1; 0; 0; 0; 0; s8 "";
875 2; 10; 0; 0; 0x010a00 *2; s8 "M";
876 2; -1; 0; 0; 0; 0; s8 "";
877 2; 17; 0; 0; 0x011100 *2; s8 "N";
878 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 2;
879 2; 25; 0; 0; 0x011900 *2; s8 "O";
880 ( 2; -1; 0; 0; 0; 0; s8 "" ) * 3;
882 dnl Variable display parameters
897 dnl Dictionary termination record.
901 "be 3ace75689a0b7faa9360936bbfe26055" \
902 "le 6e93f35d19a9882eb53ffb1b067ef7cd"
905 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
907 AT_DATA([sys-file.sps], [dnl
908 GET FILE='sys-file.sav'.
911 AT_CHECK([pspp -o pspp.csv sys-file.sps])
912 AT_CHECK([cat pspp.csv], [0], [dnl
913 Variable,Description,,Position
916 ,Display Alignment: Left,,
920 ,Display Alignment: Left,,
924 ,Display Alignment: Left,,
928 ,Display Alignment: Right,,
932 ,Display Alignment: Right,,
936 ,Display Alignment: Right,,
940 ,Display Alignment: Center,,
944 ,Display Alignment: Center,,
948 ,Display Alignment: Center,,
952 ,Display Alignment: Left,,
956 ,Display Alignment: Right,,
960 ,Display Alignment: Center,,
966 AT_SETUP([long variable names])
967 AT_KEYWORDS([sack synthetic system file positive])
968 AT_DATA([sys-file.sack], [dnl
970 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
972 7; dnl Nominal case size
973 0; dnl Not compressed
977 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
980 dnl Numeric variables.
981 2; 0; 0; 0; 0x050800 *2; s8 "LONGVARI";
982 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_A";
983 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_B";
984 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_C";
985 2; 0; 0; 0; 0x050800 *2; "CO"; i8 214; "RDINA";
986 2; 0; 0; 0; 0x050800 *2; "CO"; i8 214; "RDI_A";
987 2; 0; 0; 0; 0x050800 *2; "CO"; i8 214; "RDI_B";
989 dnl Machine integer info record.
990 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
992 dnl Machine floating-point info record.
993 7; 4; 8; 3; SYSMIS; HIGHEST; LOWEST;
995 dnl Long variable names.
997 "LONGVARI=LongVariableName1"; i8 9;
998 "LONGVA_A=LongVariableName2"; i8 9;
999 "LONGVA_B=LongVariableName3"; i8 9;
1000 "LONGVA_C=LongVariableName4"; i8 9;
1001 "CO"; i8 214; "RDINA=Co"; i8 246; "rdinate_X"; i8 9;
1002 "CO"; i8 214; "RDI_A=Co"; i8 246; "rdinate_Y"; i8 9;
1003 "CO"; i8 214; "RDI_B=Co"; i8 246; "rdinate_Z";
1006 dnl Character encoding record.
1007 7; 20; 1; 12; "windows-1252";
1009 dnl Dictionary termination record.
1013 "be 8ea5a72f3ae6e732371e92a7719c3951" \
1014 "le 02bcf02cf08b1e8fc80a858101ae22fc"
1017 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1019 AT_DATA([sys-file.sps], [dnl
1020 GET FILE='sys-file.sav'.
1023 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1024 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1025 Variable,Description,,Position
1026 LongVariableName1,Format: F8.0,,1
1027 LongVariableName2,Format: F8.0,,2
1028 LongVariableName3,Format: F8.0,,3
1029 LongVariableName4,Format: F8.0,,4
1030 Coördinate_X,Format: F8.0,,5
1031 Coördinate_Y,Format: F8.0,,6
1032 Coördinate_Z,Format: F8.0,,7
1037 AT_SETUP([very long strings])
1038 AT_KEYWORDS([sack synthetic system file positive])
1039 AT_DATA([sys-file.sack], [dnl
1041 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1043 109; dnl Nominal case size
1044 0; dnl Not compressed
1048 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1051 dnl 256-byte string.
1052 2; 255; 0; 0; 0x01FF00 *2; "S"; i8 201; s6 "Q256";
1053 (2; -1; 0; 0; 0; 0; s8 "") * 31;
1054 2; 4; 0; 0; 0x010400 *2; "S"; i8 201; "Q256_1";
1056 dnl 600-byte string.
1057 2; 255; 0; 0; 0x01FF00 *2; s8 "STR600";
1058 (2; -1; 0; 0; 0; 0; s8 "") * 31;
1059 2; 255; 0; 0; 0x01FF00 *2; s8 "STR600_1";
1060 (2; -1; 0; 0; 0; 0; s8 "") * 31;
1061 2; 96; 0; 0; 0x016000 *2; s8 "STR600_2";
1062 (2; -1; 0; 0; 0; 0; s8 "") * 11;
1064 dnl Machine integer info record.
1065 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
1067 dnl Very long string record.
1069 "S"; i8 201; "Q256=00256"; i8 0; i8 9;
1070 "STR600=00600"; i8 0; i8 9;
1073 dnl Character encoding record.
1074 7; 20; 1; 12; "windows-1252";
1076 dnl Dictionary termination record.
1080 "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#" * 4;
1082 "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#" * 9;
1083 "abcdefghijklmnopqrstuvwxyzABCDEF";
1086 "be 844a4704f669dfe292482e587d690133" \
1087 "le b76025f602bdff6a42c1e0795a8b62ff"
1090 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1092 AT_DATA([sys-file.sps], [dnl
1093 GET FILE='sys-file.sav'.
1097 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1098 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1099 Variable,Description,,Position
1100 séq256,Format: A256,,1
1101 str600,Format: A600,,2
1105 abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@a,abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#abcdefghijklmnopqrstuvwxyz
1110 AT_SETUP([data file and variable attributes])
1111 AT_KEYWORDS([sack synthetic system file positive])
1112 AT_DATA([sys-file.sack], [dnl
1114 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1116 2; dnl Nominal case size
1117 0; dnl Not compressed
1121 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1125 2; 0; 0; 0; 0x050800 *2; s8 "FIRSTVAR";
1126 2; 0; 0; 0; 0x050800 *2; s8 "SECONDVA";
1128 dnl Machine integer info record.
1129 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
1131 dnl Long variable names.
1133 "FIRSTVAR=FirstVariable"; i8 9;
1134 "SECONDVA=S"; i8 233; "condVariable"; i8 9;
1137 dnl Data file attributes record.
1139 "Attr1('Value1'"; i8 10; "''d"; i8 233; "claration''"; i8 10; ")";
1140 "S"; i8 233; "condAttr('123'"; i8 10; "'456'"; i8 10; ")";
1143 dnl Variable attributes record.
1146 "ad"; i8 232; "le('23'"; i8 10; "'34'"; i8 10; ")";
1147 "bert('123'"; i8 10; ")";
1148 "$@Role('1'"; i8 10; ")";
1149 "/S"; i8 233; "condVariable:";
1150 "xyzzy('quux'"; i8 10; ")";
1154 dnl Character encoding record.
1155 7; 20; 1; 12; "windows-1252";
1157 dnl Dictionary termination record.
1161 "be 7fff0c04f697adf45f55d8be4aaa8712" \
1162 "le 7331339199344aa58bc60d7d05d538a7"
1165 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1167 AT_DATA([sys-file.sps], [dnl
1168 GET FILE='sys-file.sav'.
1169 DISPLAY @ATTRIBUTES.
1171 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1172 AT_CHECK([cat pspp.csv], [0],
1173 [[Variable,Description,
1174 FirstVariable,Custom attributes:,
1179 SécondVariable,Custom attributes:,
1182 Table: Custom data file attributes.
1185 Attr1[2],'déclaration'
1189 AT_DATA([sys-file.sps], [dnl
1190 GET FILE='sys-file.sav'.
1193 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1194 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0],
1195 [[Variable,Description,,Position
1196 FirstVariable,Format: F8.0,,1
1198 ,Custom attributes:,,
1202 SécondVariable,Format: F8.0,,2
1203 ,Custom attributes:,,
1206 Table: Custom data file attributes.
1209 Attr1[2],'déclaration'
1216 AT_SETUP([variable roles])
1217 AT_KEYWORDS([sack synthetic system file positive])
1218 AT_DATA([sys-file.sack], [dnl
1220 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1222 7; dnl Nominal case size
1223 0; dnl Not compressed
1227 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1231 2; 0; 0; 0; 0x050800 *2; s8 "I";
1232 2; 0; 0; 0; 0x050800 *2; s8 "O";
1233 2; 0; 0; 0; 0x050800 *2; s8 "B";
1234 2; 0; 0; 0; 0x050800 *2; s8 "N";
1235 2; 0; 0; 0; 0x050800 *2; s8 "P";
1236 2; 0; 0; 0; 0x050800 *2; s8 "S";
1237 2; 0; 0; 0; 0x050800 *2; s8 "X";
1239 dnl Machine integer info record.
1240 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
1242 dnl Variable attributes record.
1244 "I:$@Role('0'"; i8 10; ")";
1245 "/O:$@Role('1'"; i8 10; ")";
1246 "/B:$@Role('2'"; i8 10; ")";
1247 "/N:$@Role('3'"; i8 10; ")";
1248 "/P:$@Role('4'"; i8 10; ")";
1249 "/S:$@Role('5'"; i8 10; ")";
1250 "/X:$@Role('6'"; i8 10; ")";
1253 dnl Character encoding record.
1254 7; 20; 1; 12; "windows-1252";
1256 dnl Dictionary termination record.
1260 "be b08b39cd005682f680d132d272f5158d" \
1261 "le 176e4ac91197f5cb8732258033cfabdc"
1264 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1266 AT_DATA([sys-file.sps], [dnl
1267 GET FILE='sys-file.sav'.
1270 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0], [dnl
1271 warning: `sys-file.sav': Invalid role for variable x.
1273 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1274 warning: `sys-file.sav': Invalid role for variable x.
1276 Variable,Description,,Position
1293 AT_SETUP([compressed data])
1294 AT_KEYWORDS([sack synthetic system file positive])
1295 AT_DATA([sys-file.sack], [dnl
1297 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1299 6; dnl Nominal case size
1300 1; dnl Simple compression
1302 -1; dnl Unspecified number of cases.
1304 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1307 dnl Numeric variables.
1308 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1309 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
1311 dnl String variable.
1312 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
1313 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
1314 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
1315 2; -1; 0; 0; 0; 0; s8 "";
1317 dnl Dictionary termination record.
1320 dnl Compressed data.
1321 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
1322 i8 253 253 253 254; i8 101 102 253 253; s8 "jklm"; s8 "nopqrstu";
1323 s8 "vwxyzABC"; s8 "DEFG"; s8 "HIJKLMNO";
1324 i8 254 253 252 0 0 0 0 0; s8 "PQRSTUVW";
1328 "be c0670e436b068f45710b98f6f7d01dc5" \
1329 "le 2e43a7f8861df4e714a192dfb3c8b2f4"
1332 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1334 AT_DATA([sys-file.sps], [dnl
1335 GET FILE='sys-file.sav'.
1339 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1340 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1341 Variable,Description,,Position
1342 num1,Format: F8.0,,1
1343 num2,Format: F8.0,,2
1346 str15,Format: A15,,5
1349 num1,num2,str4,str8,str15
1350 -99,0,,abcdefgh,0123 @&t@
1351 .,151,jklm,nopqrstu,vwxyzABC @&t@
1352 1,2,DEFG,HIJKLMNO,PQRSTUV
1357 AT_SETUP([compressed data, zero bias])
1358 AT_KEYWORDS([sack synthetic system file positive])
1359 AT_DATA([sys-file.sack], [dnl
1361 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1363 6; dnl Nominal case size
1364 1; dnl Simple compression.
1366 -1; dnl Unspecified number of cases.
1368 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1371 dnl Numeric variables.
1372 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1373 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
1375 dnl String variable.
1376 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
1377 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
1378 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
1379 2; -1; 0; 0; 0; 0; s8 "";
1381 dnl Dictionary termination record.
1384 dnl Compressed data.
1385 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
1386 i8 253 253 253 254; i8 101 102 253 253; s8 "jklm"; s8 "nopqrstu";
1387 s8 "vwxyzABC"; s8 "DEFG"; s8 "HIJKLMNO";
1388 i8 254 253 252 0 0 0 0 0; s8 "PQRSTUVW";
1392 "be 2f0d25704ee497ae833213a3e4ff5e8b" \
1393 "le 49f68a9e1ba02a2f7e9166686a0db9d9"
1396 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1398 AT_DATA([sys-file.sps], [dnl
1399 GET FILE='sys-file.sav'.
1403 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0])
1404 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1405 Variable,Description,,Position
1406 num1,Format: F8.0,,1
1407 num2,Format: F8.0,,2
1410 str15,Format: A15,,5
1413 num1,num2,str4,str8,str15
1414 1,100,,abcdefgh,0123 @&t@
1415 .,251,jklm,nopqrstu,vwxyzABC @&t@
1416 101,102,DEFG,HIJKLMNO,PQRSTUV
1421 AT_SETUP([compressed data, other bias])
1422 AT_KEYWORDS([sack synthetic system file positive])
1423 AT_DATA([sys-file.sack], [dnl
1425 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1427 6; dnl Nominal case size
1428 1; dnl Simple compression.
1430 -1; dnl Unspecified number of cases.
1432 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1435 dnl Numeric variables.
1436 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1437 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
1439 dnl String variable.
1440 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
1441 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
1442 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
1443 2; -1; 0; 0; 0; 0; s8 "";
1445 dnl Dictionary termination record.
1448 dnl Compressed data.
1449 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
1450 i8 253 253 253 254; i8 101 102 253 253; s8 "jklm"; s8 "nopqrstu";
1451 s8 "vwxyzABC"; s8 "DEFG"; s8 "HIJKLMNO";
1452 i8 254 253 252 0 0 0 0 0; s8 "PQRSTUVW";
1456 "be 668b85e3dee0797883e9933a096b8c18" \
1457 "le 5e7a9c4e88cd2dbc2322943da663868e"
1460 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1462 AT_DATA([sys-file.sps], [dnl
1463 GET FILE='sys-file.sav'.
1467 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0],
1468 [warning: `sys-file.sav' near offset 0x54: Compression bias is not the usual value of 100, or system file uses unrecognized floating-point format.
1470 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1471 "warning: `sys-file.sav' near offset 0x54: Compression bias is not the usual value of 100, or system file uses unrecognized floating-point format."
1473 Variable,Description,,Position
1474 num1,Format: F8.0,,1
1475 num2,Format: F8.0,,2
1478 str15,Format: A15,,5
1481 num1,num2,str4,str8,str15
1482 -49,50,,abcdefgh,0123 @&t@
1483 .,201,jklm,nopqrstu,vwxyzABC @&t@
1484 51,52,DEFG,HIJKLMNO,PQRSTUV
1489 m4_divert_push([PREPARE_TESTS])
1490 zcompressed_sack () {
1493 "$FL3"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1495 6; dnl Nominal case size
1496 2; dnl zlib compressed
1498 -1; dnl Unspecified number of cases.
1500 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
1503 dnl Numeric variables.
1504 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1505 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
1507 dnl String variable.
1508 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
1509 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
1510 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
1511 2; -1; 0; 0; 0; 0; s8 "";
1513 dnl Dictionary termination record.
1516 dnl ZLIB data header.
1517 i64 0x178; # zheader_ofs
1518 i64 0x1e9; # ztrailer_ofs
1519 i64 48; # ztrailer_len
1521 dnl ZLIB data block.
1523 dnl This is the compressed form of:
1525 dnl 01 64 fe fd fe fd ff fb 61 62 63 64 65 66 67 68 |.d......abcdefgh|
1526 dnl 30 31 32 33 20 20 20 20 fd fd fd fe 65 66 fd fd |0123 ....ef..|
1527 dnl 6a 6b 6c 6d 20 20 20 20 6e 6f 70 71 72 73 74 75 |jklm nopqrstu|
1528 dnl 76 77 78 79 7a 41 42 43 44 45 46 47 20 20 20 20 |vwxyzABCDEFG |
1529 dnl 48 49 4a 4b 4c 4d 4e 4f fe fd fc 00 00 00 00 00 |HIJKLMNO........|
1530 dnl 50 51 52 53 54 55 56 57 |PQRSTUVW|
1532 dnl which is the data from the "compressed data" test.
1533 hex "78 01 63 4c f9 f7 f7 df df ff bf 13 93 92 53 52";
1534 hex "d3 d2 33 0c 0c 8d 8c 15 80 e0 ef df bf ff 52 d3";
1535 hex "fe fe cd ca ce c9 05 f1 f3 f2 0b 0a 8b 8a 4b 4a";
1536 hex "cb ca 2b 2a ab 1c 9d 9c 5d 5c dd dc 41 e2 1e 9e";
1537 hex "5e de 3e be 7e fe ff fe fe 61 00 81 80 c0 a0 e0";
1538 hex "90 d0 b0 70 00 0f 3f 23 d7";
1540 dnl ZLIB data trailer fixed header:
1541 i64 -100; # ztrailer_bias
1542 i64 0; # ztrailer_zero
1543 0x3ff000; # block_size
1546 dnl ZLIB block descriptor:
1547 i64 0x178; # uncompressed_ofs
1548 i64 0x190; # compressed_ofs
1549 88; # uncompressed_size
1550 89; # compressed_size
1553 m4_divert_pop([PREPARE_TESTS])
1555 AT_SETUP([zcompressed data])
1556 AT_KEYWORDS([sack synthetic system file positive zlib])
1557 zcompressed_sack > sys-file.sack
1559 "be 2d706c3ca0cc9be7f1721f09d0d42179" \
1560 "le 3f362f338d65b0a836b3c752cc3fc5bc"
1563 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1565 AT_DATA([sys-file.sps], [dnl
1566 GET FILE='sys-file.sav'.
1570 AT_CHECK([pspp -o pspp.csv sys-file.sps])
1571 AT_CHECK([grep -v Measure pspp.csv | grep -v Display], [0], [dnl
1572 Variable,Description,,Position
1573 num1,Format: F8.0,,1
1574 num2,Format: F8.0,,2
1577 str15,Format: A15,,5
1580 num1,num2,str4,str8,str15
1581 -99,0,,abcdefgh,0123 @&t@
1582 .,151,jklm,nopqrstu,vwxyzABC @&t@
1583 1,2,DEFG,HIJKLMNO,PQRSTUV
1588 AT_BANNER([system file reader - negative])
1590 AT_SETUP([misplaced type 4 record])
1591 AT_KEYWORDS([sack synthetic system file negative])
1592 AT_DATA([sys-file.sack], [dnl
1594 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1595 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1597 dnl Numeric variable.
1598 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1604 "be 6e0bb549fff1fd1af333d51b8a6e0f43" \
1605 "le 7b62734edcee2a1689c463f2866d11b8"
1608 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1610 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1612 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1613 [error: `sys-file.sav' near offset 0xd4: Misplaced type 4 record.
1618 AT_SETUP([bad record type])
1619 AT_KEYWORDS([sack synthetic system file negative])
1620 AT_DATA([sys-file.sack], [dnl
1622 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1623 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1625 dnl Numeric variable.
1626 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1628 dnl Type 8 record (not a valid type).
1632 "be dc8f078c23046ee7db74ec1003178a11" \
1633 "le dc7f111642f0629f4370630fd092eee3"
1636 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1638 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1640 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1641 [error: `sys-file.sav' near offset 0xd4: Unrecognized record type 8.
1646 AT_SETUP([wrong number of variable positions])
1647 AT_KEYWORDS([sack synthetic system file negative])
1648 AT_DATA([sys-file.sack], [dnl
1650 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1651 2; >>2<<; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1653 dnl Numeric variable.
1654 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1656 dnl End of dictionary.
1660 "be c57e91aa426f61813c3ad91ea3a56dda" \
1661 "le 5d1a6c114b135b219473c8ad5bb44bda"
1664 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1666 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1668 AT_CHECK([pspp -O format=csv sys-file.sps], [0],
1669 [warning: `sys-file.sav': File header claims 2 variable positions but 1 were read from file.
1674 AT_SETUP([variable name may not begin with `#'])
1675 AT_KEYWORDS([sack synthetic system file negative])
1676 AT_DATA([sys-file.sack], [dnl
1678 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1679 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1681 dnl Numeric variable.
1682 2; 0; 0; 0; 0x050800 *2; s8 >>"$UM1"<<;
1684 dnl End of dictionary.
1688 "be decb7ac6defa1ab3cc7a386d1843c1ae" \
1689 "le 5279b6275633bac55d167faebccfdb14"
1692 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1694 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1696 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1697 [error: `sys-file.sav' near offset 0xb4: Invalid variable name `$UM1'.
1702 AT_SETUP([variable name may not be reserved word])
1703 AT_KEYWORDS([sack synthetic system file negative])
1704 AT_DATA([sys-file.sack], [dnl
1706 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1707 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1709 dnl Numeric variable.
1710 2; 0; 0; 0; 0x050800 *2; s8 >>"TO"<<;
1712 dnl End of dictionary.
1716 "be 57e6ad709668bbf538e2efee4af49916" \
1717 "le 523f14b611efa380bbadf7a16ea43fed"
1720 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1722 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1724 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1725 [error: `sys-file.sav' near offset 0xb4: Invalid variable name `TO'.
1730 AT_SETUP([variable width must be between 0 and 255])
1731 AT_KEYWORDS([sack synthetic system file negative])
1732 AT_DATA([sys-file.sack], [dnl
1734 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1735 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1737 dnl String variable with invalid width 256.
1738 2; 256; 0; 0; 0x050800 *2; s8 "VAR1";
1740 dnl End of dictionary.
1744 "be 170bb18589ba264a0ed2d57b41fe77e1" \
1745 "le 9528b4b5936ef5630bbd3bdd60a123c3"
1748 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1750 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1752 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1753 [error: `sys-file.sav' near offset 0xb4: Bad width 256 for variable VAR1.
1758 dnl SPSS-generated system file can contain duplicate variable names
1759 dnl (see bug #41475).
1760 AT_SETUP([duplicate variable name])
1761 AT_KEYWORDS([sack synthetic system file negative])
1762 AT_DATA([sys-file.sack], [dnl
1764 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1765 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1767 dnl Numeric variables.
1768 2; 0; 0; 0; 0x050800 *2; s8 "VAR1";
1769 2; 0; 0; 0; 0x050800 *2; s8 "VAR1";
1771 dnl End of dictionary.
1775 "be d8f5fd768ab1d641f9330a4840c71343" \
1776 "le f01e123d384cdaa7c2f7fc4791325ebf"
1779 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1781 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1784 AT_CHECK([pspp -O format=csv sys-file.sps], [0],
1785 [warning: `sys-file.sav' near offset 0xd4: Renaming variable with duplicate name `VAR1' to `VAR001'.
1787 Variable,Description,,Position
1788 var1,Format: F8.0,,1
1790 ,Display Alignment: Right,,
1792 var001,Format: F8.0,,2
1794 ,Display Alignment: Right,,
1800 AT_SETUP([variable label indicator not 0 or 1])
1801 AT_KEYWORDS([sack synthetic system file negative])
1802 AT_DATA([sys-file.sack], [dnl
1804 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1805 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1807 dnl Numeric variable.
1808 2; 0; >>2<<; 0; 0x050800 *2; s8 "VAR1";
1810 dnl End of dictionary.
1814 "be 3c5ff8d8f146457a385ca92d3d23ca8a" \
1815 "le 37e9f956d321ae57b0bf7fe2384e892b"
1818 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1820 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1822 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1823 [error: `sys-file.sav' near offset 0xb4: Variable label indicator field is not 0 or 1.
1828 AT_SETUP([invalid numeric missing value indicator])
1829 AT_KEYWORDS([sack synthetic system file negative])
1830 AT_DATA([sys-file.sack], [dnl
1832 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1833 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1835 dnl Numeric variable.
1836 2; 0; 0; >>-1<<; 0x050800 *2; s8 "VAR1";
1838 dnl End of dictionary.
1842 "be d1d0d4aedf9f053452c4b1e658ade5e2" \
1843 "le df697575499fe12921185a3d23a5d61d"
1846 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1848 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1850 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1851 ["error: `sys-file.sav' near offset 0xb4: Numeric missing value indicator field is not -3, -2, 0, 1, 2, or 3."
1856 AT_SETUP([invalid string missing value indicator])
1857 AT_KEYWORDS([sack synthetic system file negative])
1858 AT_DATA([sys-file.sack], [dnl
1860 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1861 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1863 dnl String variable.
1864 2; 8; 0; >>4<<; 0x010800 *2; s8 "VAR1";
1866 dnl End of dictionary.
1870 "be f833033be7b102fae19159989f62faa6" \
1871 "le 9704ba828bb7a36ef0262838f6b7936b"
1874 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1876 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1878 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1879 ["error: `sys-file.sav' near offset 0xb4: String missing value indicator field is not 0, 1, 2, or 3."
1884 AT_SETUP([missing string continuation record])
1885 AT_KEYWORDS([sack synthetic system file negative])
1886 AT_DATA([sys-file.sack], [dnl
1888 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1889 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1891 dnl String variable.
1892 2; 10; 0; 0; 0x010a00 *2; s8 "VAR1";
1893 >>2; 0; 0; 0; 0x050800 *2; s8 "VAR2";<<
1895 dnl End of dictionary.
1899 "be c8f9ad2b2acd2918055e2b78c1e0b4b8" \
1900 "le 1afab4d6aee90a6fe8d2dbf229e06409"
1903 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1905 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1907 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
1908 [error: `sys-file.sav' near offset 0xb4: Missing string continuation record.
1913 AT_SETUP([invalid variable format])
1914 AT_KEYWORDS([sack synthetic system file negative])
1915 AT_DATA([sys-file.sack], [dnl
1917 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1918 2; 4; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
1920 dnl Numeric variable, invalid format types.
1921 dnl No warning is issued for type 0 because it has been observed in real
1923 2; 0; 0; 0; >>0xff0800; 0<<; s8 "NUM1";
1925 dnl Numeric variable, string formats.
1926 2; 0; 0; 0; >>0x010800<<; >>0x021000<<; s8 "VAR1";
1928 dnl String variable, numeric formats.
1929 2; 4; 0; 0; >>0x050800<<; >>0x110a01<<; s8 "STR1";
1931 dnl String variable, wrong width formats.
1932 2; 4; 0; 0; >>0x010800<<; >>0x020400<<; s8 "STR2";
1934 dnl End of dictionary.
1938 "be c6ef5d8fded46443aba89adfafe15cad" \
1939 "le fccaf1764c973892f2d5adbcc2c36fb7"
1942 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
1944 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
1946 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
1947 warning: `sys-file.sav' near offset 0xc0: Variable NUM1 with width 0 has invalid print format 0xff0800.
1949 warning: `sys-file.sav' near offset 0xe0: Variable VAR1 with width 0 has invalid print format 0x10800.
1951 warning: `sys-file.sav' near offset 0xe4: Variable VAR1 with width 0 has invalid write format 0x21000.
1953 warning: `sys-file.sav' near offset 0x100: Variable STR1 with width 4 has invalid print format 0x50800.
1955 warning: `sys-file.sav' near offset 0x104: Variable STR1 with width 4 has invalid write format 0x110a01.
1957 warning: `sys-file.sav' near offset 0x120: Variable STR2 with width 4 has invalid print format 0x10800.
1959 warning: `sys-file.sav' near offset 0x124: Variable STR2 with width 4 has invalid write format 0x20400.
1964 AT_SETUP([invalid long string missing values])
1965 AT_KEYWORDS([sack synthetic system file negative])
1966 AT_DATA([sys-file.sack], [dnl
1968 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
1970 7; dnl Nominal case size
1971 0; dnl Not compressed
1975 "01 Jan 11"; "20:53:52";
1976 "PSPP synthetic test file: "; i8 244; i8 245; i8 246; i8 248; s34 "";
1979 dnl One numeric variable.
1980 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
1982 dnl Long string variables that will have missing values added with a
1984 2; 9; 0; 0; 0x010900 *2; s8 "STR1";
1985 2; -1; 0; 0; 0; 0; s8 "";
1986 2; 10; 0; 0; 0x010a00 *2; s8 "STR2";
1987 2; -1; 0; 0; 0; 0; s8 "";
1988 2; 11; 0; 0; 0x010b00 *2; s8 "STR3";
1989 2; -1; 0; 0; 0; 0; s8 "";
1991 dnl Machine integer info record.
1992 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; ENDIAN; 1252;
1994 dnl Machine floating-point info record.
1995 7; 4; 8; 3; SYSMIS; HIGHEST; LOWEST;
1997 dnl Long string variable missing values record.
1999 dnl Zero missing values (not allowed) for STR1 .
2000 COUNT("STR1"); i8 >>0<<;
2002 dnl Four missing values (not allowed) for STR2.
2003 COUNT("STR2"); i8 4;
2004 8; "abcdefgh"; 8; "ijklmnop"; 8; "qrstuvwx"; 8; "yz012345";
2006 dnl Missing values for unknown variable
2007 COUNT(>>"Nonexistent"<<); i8 1; 8; "abcdefgh";
2009 dnl Missing values for numeric variable
2010 COUNT(>>"NUM1"<<); i8 1; 8; "abcdefgh";
2012 dnl Too long missing value
2013 COUNT("STR3"); i8 1; >>COUNT("abcdefghijkl")<<;
2016 dnl Character encoding record.
2017 7; 20; 1; 12; "windows-1252";
2019 dnl Dictionary termination record.
2021 s8 "abcd"; s8 "efgh"; s8 "ijkl"; s8 "mnop"; s8 "qrst"; s8 "uvwx";
2022 s16 "yzABCDEFGHI"; s16 "JKLMNOPQR"; s16 "STUVWXYZ01";
2023 s16 "23456789abc"; s32 "defghijklmnopqstuvwxyzABC";
2027 "be 26e815cfb41eaedb435ea3c81b96215c" \
2028 "le 72d70456bd4dc88bb0a0fdb039ccdfa3"
2031 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2033 AT_DATA([sys-file.sps], [dnl
2034 GET FILE='sys-file.sav'.
2037 AT_CHECK([pspp -O format=csv sys-file.sps], [0],
2038 ["warning: `sys-file.sav' near offset 0x1f8: Long string missing values record says variable STR1 has 0 missing values, but only 1 to 3 missing values are allowed."
2040 "warning: `sys-file.sav' near offset 0x201: Long string missing values record says variable STR2 has 4 missing values, but only 1 to 3 missing values are allowed."
2042 warning: `sys-file.sav' near offset 0x242: Ignoring long string missing value record for unknown variable Nonexistent.
2044 warning: `sys-file.sav' near offset 0x257: Ignoring long string missing value record for numeric variable NUM1.
2046 "warning: `sys-file.sav' near offset 0x270: Ignoring long string missing value 0 for variable str3, with width 11, that has bad value width 12."
2048 Variable,Description,,Position
2049 num1,Format: F8.0,,1
2051 ,Display Alignment: Right,,
2055 ,Display Alignment: Left,,
2059 ,Display Alignment: Left,,
2060 ,Display Width: 10,,
2061 ,"Missing Values: ""abcdefgh""; ""ijklmnop""; ""qrstuvwx""",,
2064 ,Display Alignment: Left,,
2065 ,Display Width: 11,,
2070 AT_SETUP([weighting variable must be numeric])
2071 AT_KEYWORDS([sack synthetic system file negative])
2072 AT_DATA([sys-file.sack], [dnl
2074 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2075 2; 2; 1; >>2<<; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2077 dnl Numeric variable.
2078 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2080 dnl String variable.
2081 2; 4; 0; 0; 0x010400 *2; s8 "STR1";
2083 dnl End of dictionary.
2087 "be 82d30105e46c4896c24f9dcec26c4749" \
2088 "le 32e235119be70050eb78bf4186a5a046"
2091 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2093 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2096 AT_CHECK([pspp -O format=csv sys-file.sps], [0],
2097 [warning: `sys-file.sav': Ignoring string variable `STR1' set as weighting variable.
2099 Variable,Description,,Position
2100 num1,Format: F8.0,,1
2102 ,Display Alignment: Right,,
2106 ,Display Alignment: Left,,
2112 AT_SETUP([bad weighting variable index])
2113 AT_KEYWORDS([sack synthetic system file negative])
2114 AT_DATA([sys-file.sack], [dnl
2116 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2117 2; 2; 1; >>3<<; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2119 dnl Numeric variable.
2120 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2122 dnl String variable.
2123 2; 4; 0; 0; 0x010400 *2; s8 "STR1";
2125 dnl End of dictionary.
2129 "be cd9af924ff20bc75834aa2c696254c97" \
2130 "le cbe0f2f514f5e95f27644d0b4314bc78"
2133 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2135 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2137 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
2138 [error: `sys-file.sav' near offset 0x4c: Variable index 3 not in valid range 1...2.
2143 AT_SETUP([variable index is long string contination])
2144 AT_KEYWORDS([sack synthetic system file negative])
2145 AT_DATA([sys-file.sack], [dnl
2147 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2148 2; 2; 1; >>3<<; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2150 dnl Numeric variable.
2151 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2153 dnl Long string variable.
2154 2; 9; 0; 0; 0x010900 *2; s8 "STR1";
2155 (2; -1; 0; 0; 0; 0; s8 "");
2157 dnl End of dictionary.
2161 "be 0c395354df56ea5ff374aafcc535d633" \
2162 "le d977f684ea9d4648ed40f8c6dddde9f7"
2165 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2167 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2169 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
2170 [error: `sys-file.sav' near offset 0x4c: Variable index 3 refers to long string continuation.
2175 AT_SETUP([multiple documents records])
2176 AT_KEYWORDS([sack synthetic system file negative])
2177 AT_DATA([sys-file.sack], [dnl
2179 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2180 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2182 dnl Numeric variable, no label or missing values.
2183 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2185 dnl Two document records.
2186 (6; 1; s80 "One line of documents") >>* 2<<;
2188 dnl Dictionary termination record.
2195 "be 18aa3348a216ed494efe28285b348fa8" \
2196 "le 19b21522bcef1dcc60af328f923f307e"
2199 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2201 AT_DATA([sys-file.sps], [dnl
2202 GET FILE='sys-file.sav'.
2204 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2205 error: `sys-file.sav' near offset 0x12c: Duplicate type 6 (document) record.
2211 AT_SETUP([empty document record])
2212 AT_KEYWORDS([sack synthetic system file negative])
2213 AT_DATA([sys-file.sack], [dnl
2215 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2216 2; 2; 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 Empty document record.
2224 dnl Dictionary termination record.
2231 "be d8ef29c1b97f9ed226cbd938c9c49b6e" \
2232 "le f6a560c5b62e2c472429d85294f36e61"
2235 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2237 AT_DATA([sys-file.sps], [dnl
2238 GET FILE='sys-file.sav'.
2240 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2241 error: `sys-file.sav' near offset 0xd4: Number of document lines (0) must be greater than 0 and less than 26843545.
2246 AT_SETUP([extension record too large])
2247 AT_KEYWORDS([sack synthetic system file negative])
2248 AT_DATA([sys-file.sack], [dnl
2250 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2251 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2253 dnl Numeric variable, no label or missing values.
2254 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2256 dnl Too-large extension record.
2257 7; 3; >>0xfffff000 * 2<<;
2260 "be 5a6679dc41ac349b0b73fc430937c05c" \
2261 "le d4769c7f650cfbf160e0386d0d33be04"
2264 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2266 AT_DATA([sys-file.sps], [dnl
2267 GET FILE='sys-file.sav'.
2269 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2270 error: `sys-file.sav' near offset 0xd8: Record type 7 subtype 3 too large.
2275 AT_SETUP([unknown extension record])
2276 AT_KEYWORDS([sack synthetic system file negative])
2277 AT_DATA([sys-file.sack], [dnl
2279 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2280 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2282 dnl Numeric variable, no label or missing values.
2283 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2285 dnl Unknown extension record type.
2288 dnl End of dictionary.
2292 "be ac8395e27677408189bcb8655e56cc0e" \
2293 "le e308bfcd51f1e3c28d7379c29271f9d6"
2296 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2298 AT_DATA([sys-file.sps], [dnl
2299 GET FILE='sys-file.sav'.
2301 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2302 "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."
2307 AT_SETUP([bad machine integer info size])
2308 AT_KEYWORDS([sack synthetic system file negative])
2309 AT_DATA([sys-file.sack], [dnl
2311 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2312 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2314 dnl Numeric variable, no label or missing values.
2315 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2317 dnl Machine integer info record.
2318 7; 3; 4; >>9<<; 1; 2; 3; -1; 1; 1; ENDIAN; 1252; >>1234<<;
2320 dnl End of dictionary.
2324 "be 21ec84826886b0a266d1360f8279d769" \
2325 "le 15dcba7b2b89b7d8a21ebcc872f515af"
2328 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
2329 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2331 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2332 "warning: `sys-file.sav' near offset 0xd8: Record type 7, subtype 3 has bad count 9 (expected 8)."
2337 AT_SETUP([bad machine integer info float format])
2338 AT_KEYWORDS([sack synthetic system file negative])
2339 AT_DATA([sys-file.sack], [dnl
2341 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2342 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2344 dnl Numeric variable, no label or missing values.
2345 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2347 dnl Machine integer info record.
2348 7; 3; 4; 8; 1; 2; 3; -1; >>2<<; 1; ENDIAN; 1252;
2350 dnl End of dictionary.
2354 "be d510ed28278649eee997fb6881a4c04f" \
2355 "le fbf1eca561a4e243b7ae844ed1677035"
2358 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
2359 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2361 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
2362 error: `sys-file.sav' near offset 0xd8: Floating-point representation indicated by system file (2) differs from expected (1).
2367 AT_SETUP([bad machine integer info endianness])
2368 AT_KEYWORDS([sack synthetic system file negative])
2369 AT_DATA([sys-file.sack], [dnl
2371 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2372 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2374 dnl Numeric variable, no label or missing values.
2375 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2377 dnl Machine integer info record.
2378 7; 3; 4; 8; 1; 2; 3; -1; 1; 1; >>3<<; 1252;
2380 dnl End of dictionary.
2384 "be 855123d16d5e1560b91d60753dad79ad 1" \
2385 "le d6626b4fa2e46a91f26c2fc609b2f1e0 2"
2388 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2390 AT_DATA([sys-file.sps], [dnl
2391 GET FILE='sys-file.sav'.
2394 AT_CHECK_UNQUOTED([pspp -O format=csv sys-file.sps], [0], [dnl
2395 warning: \`sys-file.sav' near offset 0xd8: Integer format indicated by system file (3) differs from expected ($[3]).
2397 Variable,Description,,Position
2398 num1,Format: F8.0,,1
2400 ,Display Alignment: Right,,
2407 AT_SETUP([bad machine floating-point info size])
2408 AT_KEYWORDS([sack synthetic system file negative])
2409 AT_DATA([sys-file.sack], [dnl
2411 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2412 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2414 dnl Numeric variable, no label or missing values.
2415 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2417 dnl Machine floating-point info record.
2418 7; 4; 8; >>4<<; SYSMIS; HIGHEST; LOWEST; 0.0;
2420 dnl End of dictionary.
2424 "be 29c9a173638fbb8bb1efe1176c4d670f" \
2425 "le 5cb49eb1084e5b9cd573a54705ff86a7"
2428 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
2429 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2431 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2432 "warning: `sys-file.sav' near offset 0xd8: Record type 7, subtype 4 has bad count 4 (expected 3)."
2437 AT_SETUP([wrong special floating point values])
2438 AT_KEYWORDS([sack synthetic system file negative])
2439 AT_DATA([sys-file.sack], [dnl
2441 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2442 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2444 dnl Numeric variable, no label or missing values.
2445 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2447 dnl Machine floating-point info record.
2448 7; 4; 8; 3; >>0.0<<; >>1.0<<; >>2.0<<;
2450 dnl End of dictionary.
2454 "be 1e7452d9bb0a2397bf6084a25437514e" \
2455 "le f59f9a83f723cde1611869ff6d91d325"
2458 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2460 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2462 AT_CHECK([pspp -O format=csv sys-file.sps | sed 's/ [(].*/.../'], [0], [dnl
2463 "warning: `sys-file.sav' near offset 0xd8: File specifies unexpected value 0...
2465 "warning: `sys-file.sav' near offset 0xd8: File specifies unexpected value 1...
2467 "warning: `sys-file.sav' near offset 0xd8: File specifies unexpected value 2...
2472 AT_SETUP([bad mrsets name])
2473 AT_KEYWORDS([sack synthetic system file negative multiple response])
2474 AT_DATA([sys-file.sack], [dnl
2476 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2477 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2479 dnl Numeric variable, no label or missing values.
2480 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2482 dnl Multiple response sets.
2483 7; 7; 1; COUNT("a=C");
2484 7; 19; 1; COUNT("xyz=D");
2489 "be 15a9bf44d0cd6186a60629b77079c5a5" \
2490 "le 161c99aca5e7a3684df096137e72ce5b"
2493 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2495 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2497 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2498 warning: `sys-file.sav' near offset 0xd8: `a' does not begin with `$' at offset 2 in MRSETS record.
2500 warning: `sys-file.sav' near offset 0xeb: `xyz' does not begin with `$' at offset 4 in MRSETS record.
2505 AT_SETUP([missing space after C in mrsets])
2506 AT_KEYWORDS([sack synthetic system file negative multiple response])
2507 AT_DATA([sys-file.sack], [dnl
2509 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2510 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2512 dnl Numeric variable, no label or missing values.
2513 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2515 dnl Multiple response sets.
2516 7; 7; 1; COUNT("$a=Cx");
2521 "be c5e5656ba3d74c3a967850f29ad89970" \
2522 "le 29f110509c3d6893a7d21ae2d66aad9d"
2525 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2527 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2529 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2530 warning: `sys-file.sav' near offset 0xd8: Missing space following `C' at offset 4 in MRSETS record.
2535 AT_SETUP([missing space after E in mrsets])
2536 AT_KEYWORDS([sack synthetic system file negative multiple response])
2537 AT_DATA([sys-file.sack], [dnl
2539 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2540 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2542 dnl Numeric variable, no label or missing values.
2543 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2545 dnl Multiple response sets.
2546 7; 7; 1; COUNT("$a=Ex");
2551 "be a9e1dc63e2524882a5e3d2949a2da9d4" \
2552 "le ac709ca1928f65f47a8c8efdd9454b50"
2555 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2557 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2559 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2560 warning: `sys-file.sav' near offset 0xd8: Missing space following `E' at offset 4 in MRSETS record.
2565 AT_SETUP([unexpected label source in mrsets])
2566 AT_KEYWORDS([sack synthetic system file negative multiple response])
2567 AT_DATA([sys-file.sack], [dnl
2569 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2570 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2572 dnl Numeric variable, no label or missing values.
2573 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2575 dnl Multiple response sets.
2576 7; 7; 1; COUNT("$a=E 2");
2581 "be 8c710e85a0a1609d0d03dec80aaf5f94" \
2582 "le 4682440b82f22d4bd2ac56afb7fa3152"
2585 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2587 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2589 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2590 warning: `sys-file.sav' near offset 0xd8: Unexpected label source value `2' following `E' at offset 7 in MRSETS record.
2592 warning: `sys-file.sav' near offset 0xd8: Expecting digit at offset 7 in MRSETS record.
2597 AT_SETUP([bad type character in mrsets])
2598 AT_KEYWORDS([sack synthetic system file negative multiple response])
2599 AT_DATA([sys-file.sack], [dnl
2601 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2602 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2604 dnl Numeric variable, no label or missing values.
2605 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2607 dnl Multiple response sets.
2608 7; 7; 1; COUNT("$a=");
2613 "be fc5e5200d8f56b9a5a713e4a95313a3b" \
2614 "le 578a61e8a06b20216612f566c2050879"
2617 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2619 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2621 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2622 "warning: `sys-file.sav' near offset 0xd8: Missing `C', `D', or `E' at offset 3 in MRSETS record."
2627 AT_SETUP([bad counted string length in mrsets])
2628 AT_KEYWORDS([sack synthetic system file negative multiple response])
2629 AT_DATA([sys-file.sack], [dnl
2631 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2632 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2634 dnl Numeric variable, no label or missing values.
2635 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2637 dnl Multiple response sets.
2638 7; 7; 1; COUNT("$a=Dx");
2643 "be 23d0e2f65c7c5f93bbedcc0f2b260c69" \
2644 "le c3860c1d80e08842264948056e72c0db"
2647 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2649 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2651 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2652 warning: `sys-file.sav' near offset 0xd8: Expecting digit at offset 4 in MRSETS record.
2657 AT_SETUP([missing space in counted string in mrsets])
2658 AT_KEYWORDS([sack synthetic system file negative multiple response])
2659 AT_DATA([sys-file.sack], [dnl
2661 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2662 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2664 dnl Numeric variable, no label or missing values.
2665 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2667 dnl Multiple response sets.
2668 7; 7; 1; COUNT("$a=D1x");
2673 "be c9ce001723763e0698878b7e43a887e8" \
2674 "le e258a1e4491d5a1d1e7d2272ef631a22"
2677 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2679 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2681 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2682 warning: `sys-file.sav' near offset 0xd8: Expecting space at offset 5 in MRSETS record.
2687 AT_SETUP([counted string too long in mrsets])
2688 AT_KEYWORDS([sack synthetic system file negative multiple response])
2689 AT_DATA([sys-file.sack], [dnl
2691 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2692 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2694 dnl Numeric variable, no label or missing values.
2695 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2697 dnl Multiple response sets.
2698 7; 7; 1; COUNT("$a=D4 abc");
2703 "be 196d1266fa0e8e315769dcbe3130e3df" \
2704 "le 23df1ba7b77a26da8ce1c2cfbcaadce0"
2707 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2709 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2711 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2712 warning: `sys-file.sav' near offset 0xd8: 4-byte string starting at offset 6 exceeds record length 9.
2717 AT_SETUP([missing space after counted string in mrsets])
2718 AT_KEYWORDS([sack synthetic system file negative multiple response])
2719 AT_DATA([sys-file.sack], [dnl
2721 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2722 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2724 dnl Numeric variable, no label or missing values.
2725 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2727 dnl Multiple response sets.
2728 7; 7; 1; COUNT("$a=D3 abcx");
2733 "be 86314bb0bbdfad48c10af8b8d8106d6e" \
2734 "le 2b8d05ff501ca78e51f7110ce88a2364"
2737 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2739 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2741 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2742 warning: `sys-file.sav' near offset 0xd8: Expecting space at offset 9 following 3-byte string.
2747 AT_SETUP([missing newline after variable name in mrsets])
2748 AT_KEYWORDS([sack synthetic system file negative multiple response])
2749 AT_DATA([sys-file.sack], [dnl
2751 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2752 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2754 dnl Numeric variable, no label or missing values.
2755 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2757 dnl Multiple response sets.
2758 7; 7; 1; COUNT("$a=C 0 NUM1");
2763 "be cea939cf3e6a5f88cb45e8fa871c5e13" \
2764 "le 52135afec082f50f37eafacadbb2cd65"
2767 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2769 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2771 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2772 warning: `sys-file.sav' near offset 0xd8: Missing new-line parsing variable names at offset 13 in MRSETS record.
2774 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2779 AT_SETUP([duplicate variable name in mrsets])
2780 AT_KEYWORDS([sack synthetic system file negative multiple response])
2781 AT_DATA([sys-file.sack], [dnl
2783 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2784 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2786 dnl Numeric variable, no label or missing values.
2787 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2789 dnl Multiple response sets.
2790 7; 7; 1; COUNT("$a=C 0 NUM1 NUM1"; i8 10);
2795 "be 4b1b5fa2dc22cf0afdd35422290b0a29" \
2796 "le e4304b57976440a036f25f8dd8ac1404"
2799 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2801 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2803 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2804 warning: `sys-file.sav' near offset 0xd8: Duplicate variable name NUM1 at offset 18 in MRSETS record.
2806 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2811 AT_SETUP([mixed variable types in mrsets])
2812 AT_KEYWORDS([sack synthetic system file negative multiple response])
2813 AT_DATA([sys-file.sack], [dnl
2815 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2816 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2819 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2820 2; 8; 0; 0; 0x010800 *2; s8 "STR1";
2822 dnl Multiple response sets.
2823 7; 7; 1; COUNT("$a=C 0 NUM1 STR1"; i8 10);
2828 "be 0f130e967e4097823f85b8711eb20727" \
2829 "le 4dc987b4303fd115f1cae9be3963acc9"
2832 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2834 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2836 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2837 warning: `sys-file.sav' near offset 0xf8: MRSET $a contains both string and numeric variables.
2839 warning: `sys-file.sav' near offset 0xf8: MRSET $a has only 1 variables.
2844 AT_SETUP([missing newline after variable name in mrsets])
2845 AT_KEYWORDS([sack synthetic system file negative multiple response])
2846 AT_DATA([sys-file.sack], [dnl
2848 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2849 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2851 dnl Numeric variable, no label or missing values.
2852 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2854 dnl Multiple response sets.
2855 7; 7; 1; COUNT("$a=C 0 NUM1"; i8 10);
2860 "be 3a891e0a467afb3d622629c70f329ada" \
2861 "le 432998ec08370510411af4f5207c015e"
2864 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2866 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2868 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2869 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2874 AT_SETUP([only one variable in mrset])
2875 AT_KEYWORDS([sack synthetic system file negative multiple response])
2876 AT_DATA([sys-file.sack], [dnl
2878 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2879 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2881 dnl Numeric variable, no label or missing values.
2882 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2884 dnl Multiple response sets.
2885 7; 7; 1; COUNT("$a=C 0 NUM1"; i8 10);
2890 "be 3a891e0a467afb3d622629c70f329ada" \
2891 "le 432998ec08370510411af4f5207c015e"
2894 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2896 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2898 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2899 warning: `sys-file.sav' near offset 0xd8: MRSET $a has only 1 variables.
2904 AT_SETUP([wrong display parameter size])
2905 AT_KEYWORDS([sack synthetic system file negative])
2906 AT_DATA([sys-file.sack], [dnl
2908 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2909 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2911 dnl Numeric variable, no label or missing values.
2912 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2914 dnl Display parameters record.
2915 7; 11; >>8<<; 2; 1.0; 1.0;
2917 dnl End of dictionary.
2921 "be 7c0f1ae47ae11e37d435c4abaceca226" \
2922 "le c29d05a1f8f15ed2201f31f8b787aaa0"
2925 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2927 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2929 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2930 "warning: `sys-file.sav' near offset 0xd8: Record type 7, subtype 11 has bad size 8 (expected 4)."
2935 AT_SETUP([wrong display parameter count])
2936 AT_KEYWORDS([sack synthetic system file negative])
2937 AT_DATA([sys-file.sack], [dnl
2939 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2940 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2942 dnl Numeric variable, no label or missing values.
2943 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2945 dnl Display parameters record.
2946 7; 11; 4; >>4<<; 1; 1; 2; 2;
2948 dnl End of dictionary.
2952 "be 372b57e73c69b05047b60bf6c596e2a1" \
2953 "le 2a550d8c5ceae4de7ced77df66e49d0f"
2956 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2958 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2960 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2961 warning: `sys-file.sav' near offset 0xd8: Extension 11 has bad count 4 (for 1 variables).
2966 AT_SETUP([wrong display measurement level])
2967 AT_KEYWORDS([sack synthetic system file negative])
2968 AT_DATA([sys-file.sack], [dnl
2970 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
2971 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
2973 dnl Numeric variable, no label or missing values.
2974 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
2976 dnl Display parameters record.
2977 7; 11; 4; 2; >>4<<; 0;
2979 dnl End of dictionary.
2983 "be d43e7616b03743339f37292dec6c2204" \
2984 "le 821533c29a070cefdd8f07f4e1741d2a"
2987 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
2989 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
2991 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
2992 warning: `sys-file.sav' near offset 0xd8: Invalid variable display parameters for variable 0 (NUM1). Default parameters substituted.
2997 AT_SETUP([wrong display alignment])
2998 AT_KEYWORDS([sack synthetic system file negative])
2999 AT_DATA([sys-file.sack], [dnl
3001 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3002 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3004 dnl Numeric variable, no label or missing values.
3005 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3007 dnl Display parameters record.
3008 7; 11; 4; 2; 1; >>-1<<;
3010 dnl End of dictionary.
3014 "be c54bc48b5767e2ec3a9ef31df790cb7c" \
3015 "le a4d8b14af64221abe83adb417d110e10"
3018 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3020 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3022 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3023 warning: `sys-file.sav' near offset 0xd8: Invalid variable display parameters for variable 0 (NUM1). Default parameters substituted.
3028 AT_SETUP([bad variable name in variable/value pair])
3029 AT_KEYWORDS([sack synthetic system file negative])
3030 AT_DATA([sys-file.sack], [dnl
3032 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3033 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3035 dnl Numeric variables.
3036 2; 0; 0; 0; 0x050800 *2; s8 "LONGVARI";
3038 dnl Long variable names.
3039 7; 13; 1; COUNT (>>"xyzzy"<<);
3041 dnl Dictionary termination record.
3045 "be b67b6e3c1900e5a9cc691055008f0447" \
3046 "le 26cc52e601f830f9087a0ea2bd9527df"
3049 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3051 AT_DATA([sys-file.sps], [dnl
3052 GET FILE='sys-file.sav'.
3054 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3055 warning: `sys-file.sav' near offset 0xde: Dictionary record refers to unknown variable xyzzy.
3060 AT_SETUP([duplicate long variable name])
3061 AT_KEYWORDS([sack synthetic system file negative])
3062 AT_DATA([sys-file.sack], [dnl
3064 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3065 2; 4; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3067 dnl Numeric variables.
3068 2; 0; 0; 0; 0x050800 *2; s8 "LONGVARI";
3069 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_A";
3070 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_B";
3071 2; 0; 0; 0; 0x050800 *2; s8 "LONGVA_C";
3073 dnl Long variable names.
3075 "LONGVARI=_Invalid"; i8 9;
3076 "LONGVA_A=LongVariableName"; i8 9;
3077 "LONGVA_B=LONGVARIABLENAME"; i8 9;
3080 dnl Dictionary termination record.
3084 "be 9b4b4daa00084d984efb8f889bcb727c" \
3085 "le c1b1470d5cd615106e9ae507c9948d8e"
3088 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3090 AT_DATA([sys-file.sps], [dnl
3091 GET FILE='sys-file.sav'.
3093 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3094 warning: `sys-file.sav' near offset 0x138: Long variable mapping from LONGVARI to invalid variable name `_Invalid'.
3096 warning: `sys-file.sav' near offset 0x138: Duplicate long variable name `LONGVARIABLENAME'.
3101 AT_SETUP([bad very long string length])
3102 AT_KEYWORDS([sack synthetic system file negative])
3103 AT_DATA([sys-file.sack], [dnl
3105 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3106 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3108 dnl Numeric variable.
3109 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3111 dnl Very long string map.
3113 "NUM1=00000"; i8 0; i8 9;
3114 "NUM1=00255"; i8 0; i8 9;
3115 "NUM1=00256"; i8 0; i8 9;
3118 dnl Dictionary termination record.
3122 "be 1309d8d9fb24bcf08952dce9b0f39a94" \
3123 "le 94a39de88f8034001b3e467c4cc04d0f"
3126 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3128 AT_DATA([sys-file.sps], [dnl
3129 GET FILE='sys-file.sav'.
3131 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
3132 warning: `sys-file.sav' near offset 0xd8: NUM1 listed as string of invalid length 00000 in very long string record.
3134 "warning: `sys-file.sav' near offset 0xd8: NUM1 listed in very long string record with width 00255, which requires only one segment."
3136 error: `sys-file.sav' near offset 0xd8: Very long string NUM1 overflows dictionary.
3141 AT_SETUP([bad very long string segment width])
3142 AT_KEYWORDS([sack synthetic system file negative])
3143 AT_DATA([sys-file.sack], [dnl
3145 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3146 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3149 2; 255; 0; 0; 0x01ff00 *2; s8 "STR1";
3150 (2; -1; 0; 0; 0; 0; s8 "") * 31;
3151 2; >>9<<; 0; 0; 0x010900 *2; s8 "STR1_A";
3152 >>2; -1; 0; 0; 0; 0; s8 "";<<
3154 dnl Very long string map.
3156 "STR1=00256"; i8 0; i8 9;
3159 dnl Dictionary termination record.
3163 "be 1d09a44a46859e6eda28e053dd4b7a8b" \
3164 "le 63b9ac0b3953f3e0d5ee248ebe257794"
3167 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3169 AT_DATA([sys-file.sps], [dnl
3170 GET FILE='sys-file.sav'.
3172 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
3173 error: `sys-file.sav' near offset 0x4f8: Very long string with width 256 has segment 1 of width 9 (expected 4).
3178 AT_SETUP([too many value labels])
3179 dnl Skip the test if multiplying a small number by INT32_MAX would not
3180 dnl cause an overflow in size_t.
3181 AT_SKIP_IF([test $SIZEOF_SIZE_T -gt 4])
3182 AT_KEYWORDS([sack synthetic system file negative])
3183 AT_DATA([sys-file.sack], [dnl
3185 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3186 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3188 dnl Numeric variable.
3189 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3193 "be 975b2668dde395ddf619977958b37412" \
3194 "le 0c14aa278cfc2a4b801f91c14321f03b"
3197 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3199 AT_DATA([sys-file.sps], [dnl
3200 GET FILE='sys-file.sav'.
3202 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
3203 error: `sys-file.sav' near offset 0xd4: Invalid number of labels 2147483647.
3208 AT_SETUP([missing type 4 record])
3209 AT_KEYWORDS([sack synthetic system file negative])
3210 AT_DATA([sys-file.sack], [dnl
3212 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3213 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3215 dnl Numeric variable.
3216 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3218 dnl Value label with missing type 4 record.
3219 3; 1; 1.0; i8 3; s7 "one";
3221 dnl End of dictionary.
3225 "be 5e1286ac92e3f25ff98492bc5019d608" \
3226 "le b33c12f776bbcaa43aa3bfdd4799e0c0"
3229 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3231 AT_DATA([sys-file.sps], [dnl
3232 GET FILE='sys-file.sav'.
3234 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
3235 error: `sys-file.sav' near offset 0xe8: Variable index record (type 4) does not immediately follow value label record (type 3) as it should.
3240 AT_SETUP([value label with no associated variables])
3241 AT_KEYWORDS([sack synthetic system file negative])
3242 AT_DATA([sys-file.sack], [dnl
3244 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3245 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3247 dnl Numeric variable.
3248 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3250 dnl Value label with no variables.
3251 3; 1; 1.0; i8 3; s7 "one"; 4; >>0<<;
3254 "be b0dcec30a936cbcad21c4f3d6fe10fcf" \
3255 "le 3b9fdfce5c8c248048232fd6eac018e3"
3258 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3260 AT_DATA([sys-file.sps], [dnl
3261 GET FILE='sys-file.sav'.
3263 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
3264 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).
3269 AT_SETUP([type 4 record names long string variable])
3270 AT_KEYWORDS([sack synthetic system file negative])
3271 AT_DATA([sys-file.sack], [dnl
3273 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3274 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3276 dnl Long string variable.
3277 2; 9; 0; 0; 0x010900 *2; s8 "STR1";
3278 2; -1; 0; 0; 0; 0; s8 "";
3280 dnl Value label that names long string variable.
3281 3; 1; s8 "xyzzy"; i8 3; s7 "one"; 4; 1; >>1<<;
3283 dnl End of dictionary.
3287 "be 14053a4f09de4c7c4c55281534dd66f4" \
3288 "le 8a61cc994c659fd66307d2f0fd64ce20"
3291 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
3292 AT_DATA([sys-file.sps], [dnl
3293 GET FILE='sys-file.sav'.
3295 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
3296 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.
3301 AT_SETUP([variables for value label must all be same type])
3302 AT_KEYWORDS([sack synthetic system file negative])
3303 AT_DATA([sys-file.sack], [dnl
3305 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3306 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3309 2; 6; 0; 0; 0x010600 *2; s8 "STR1";
3310 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3312 dnl Value label that names numeric and string variables.
3313 3; 1; s8 "xyzzy"; i8 3; s7 "one"; 4; 2; >>1; 2<<;
3315 dnl End of dictionary.
3319 "be 7577c456726a88f52bbef63a8b47bf1a" \
3320 "le 3ba5c6af9ad0ae5cc88f9f63e726e414"
3323 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [ignore])
3324 AT_DATA([sys-file.sps], [dnl
3325 GET FILE='sys-file.sav'.
3327 AT_CHECK([pspp -O format=csv sys-file.sps], [1], [dnl
3328 "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."
3333 AT_SETUP([duplicate value labels type])
3334 AT_KEYWORDS([sack synthetic system file negative])
3335 AT_DATA([sys-file.sack], [dnl
3337 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3338 2; 2; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3341 2; 6; 0; 0; 0x010600 *2; s8 "STR1";
3342 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3344 dnl Duplicate value labels.
3345 3; 1; s8 "xyzzy"; i8 3; s7 "one"; 4; 2; >>1; 1<<;
3346 3; 1; 1.0; i8 3; s7 "one"; 4; 2; >>2; 2<<;
3348 dnl End of dictionary.
3352 "be ef0f5b2ebddb5a3bfcda16c93a2508f4" \
3353 "le c00e27abd9a6c06bf29a108d7220435a"
3356 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3358 AT_DATA([sys-file.sps], [dnl
3359 GET FILE='sys-file.sav'.
3361 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3362 warning: `sys-file.sav' near offset 0xf4: Duplicate value label for `xyzzy ' on STR1.
3364 warning: `sys-file.sav' near offset 0x11c: Duplicate value label for 1 on NUM1.
3369 AT_SETUP([missing attribute value])
3370 AT_KEYWORDS([sack synthetic system file negative])
3371 AT_DATA([sys-file.sack], [dnl
3373 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3374 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3377 2; 0; 0; 0; 0x050800 *2; s8 "FIRSTVAR";
3379 dnl Data file attributes record.
3384 dnl Variable attributes record.
3390 dnl Dictionary termination record.
3394 "be 0fc71f5e3cdb6b7f2dd73d011d4885c2" \
3395 "le e519b44715400156a2bfe648eb5cff34"
3398 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3400 AT_DATA([sys-file.sps], [dnl
3401 GET FILE='sys-file.sav'.
3403 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3404 warning: `sys-file.sav' near offset 0xde: Error parsing attribute value Attr1[[1]].
3406 warning: `sys-file.sav' near offset 0x101: Error parsing attribute value fred[[2]].
3411 AT_SETUP([unquoted attribute value])
3412 AT_KEYWORDS([sack synthetic system file negative])
3413 AT_DATA([sys-file.sack], [dnl
3415 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3416 2; 1; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3419 2; 0; 0; 0; 0x050800 *2; s8 "FIRSTVAR";
3421 dnl Data file attributes record.
3423 "Attr1(value"; i8 10;
3427 dnl Variable attributes record.
3430 "fred(23"; i8 10; ")"
3433 dnl Dictionary termination record.
3437 "be 33dba37c2247e63c04bb74a7b472293d" \
3438 "le 041025a9d9d9e21a7fabd90ba7341934"
3441 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3443 AT_DATA([sys-file.sps], [dnl
3444 GET FILE='sys-file.sav'.
3446 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3447 warning: `sys-file.sav' near offset 0xe4: Attribute value Attr1[[1]] is not quoted: value.
3449 warning: `sys-file.sav' near offset 0x106: Attribute value fred[[1]] is not quoted: 23.
3454 AT_SETUP([bad variable name in long string value label])
3455 AT_KEYWORDS([sack synthetic system file negative])
3456 AT_DATA([sys-file.sack], [dnl
3458 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3459 2; 3; 1; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3462 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3463 2; 14; 0; 0; 0x010e00 *2; s8 "STR14";
3464 2; -1; 0; 0; 0; 0; s8 "";
3467 dnl No variable named STR9.
3468 COUNT(>>"STR9"<<); 9;
3469 1; COUNT("RSTUVWXYZ"); COUNT("value label for `RSTUVWXYZ'");
3471 dnl NUM1 is numeric.
3472 COUNT(>>"NUM1"<<); 0;
3473 1; COUNT("xyz"); COUNT("value label for 1.0");
3475 dnl Wrong width for STR14.
3476 COUNT("STR14"); >>9<<;
3477 1; COUNT("RSTUVWXYZ"); COUNT("value label for `RSTUVWXYZ'");
3479 dnl Wrong width for value.
3481 1; COUNT(>>"RSTUVWXYZ"<<); COUNT("value label for `RSTUVWXYZ'");
3483 dnl Duplicate value label.
3484 COUNT("STR14"); 14; 2;
3485 COUNT("abcdefghijklmn"); COUNT("value label for `abcdefghijklmn'");
3486 >>COUNT("abcdefghijklmn"); COUNT("another value label for `abcdefghijklmn'")<<;
3489 dnl Dictionary termination record.
3493 "be cf2e883dadb00e2c6404c09ea0a4e388" \
3494 "le 89c340faf0a7e4a8c834f9687684c091"
3497 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3499 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3501 AT_CHECK([pspp -O format=csv sys-file.sps], [0], [dnl
3502 warning: `sys-file.sav' near offset 0x128: Ignoring long string value label record for unknown variable STR9.
3504 warning: `sys-file.sav' near offset 0x164: Ignoring long string value label record for numeric variable NUM1.
3506 warning: `sys-file.sav' near offset 0x193: Ignoring long string value label record for variable STR14 because the record's width (9) does not match the variable's width (14).
3508 "warning: `sys-file.sav' near offset 0x1d4: Ignoring long string value label 0 for variable str14, with width 14, that has bad value width 9."
3510 warning: `sys-file.sav' near offset 0x259: Duplicate value label for `abcdefghijklmn' on str14.
3515 AT_SETUP([fewer data records than indicated by file header])
3516 AT_KEYWORDS([sack synthetic system file negative])
3517 AT_DATA([sys-file.sack], [dnl
3519 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3520 2; 2; 0; 0; >>5<<; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3522 dnl Numeric variables.
3523 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3524 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
3532 dnl Missing record here.
3535 "be 6ee097c3934055d0c4564641636f4b5a" \
3536 "le ae03fe1b888091d6938b5a436d44ac60"
3539 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3541 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3544 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3545 [error: Error reading case from file `sys-file.sav'.
3557 AT_SETUP([partial data record between variables])
3558 AT_KEYWORDS([sack synthetic system file negative])
3559 AT_DATA([sys-file.sack], [dnl
3561 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3562 2; 2; 0; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3564 dnl Numeric variables.
3565 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3566 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
3574 "be 4bcc085d7d8f0f09c6a4ba8064ffe61c" \
3575 "le 7387fc5edd2740aff92c30ca688d6d9b"
3578 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3580 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3583 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3584 [error: `sys-file.sav' near offset 0x110: File ends in partial case.
3593 AT_SETUP([partial data record within long string])
3594 AT_KEYWORDS([sack synthetic system file negative])
3595 AT_DATA([sys-file.sack], [dnl
3597 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3598 2; 2; 0; 0; -1; 100.0; "01 Jan 11"; "20:53:52"; s64 ""; i8 0 *3;
3600 dnl Numeric variables.
3601 2; 14; 0; 0; 0x010e00 *2; s8 "STR14";
3602 2; -1; 0; 0; 0; 0; s8 "";
3606 s14 "one data item";
3610 "be 4a9e84f9e679afb7bb71acd0bb7eab89" \
3611 "le 30752606f14ee2deec2854e8e6de4b3b"
3614 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3616 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3619 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3620 [error: `sys-file.sav' near offset 0x10e: Unexpected end of file.
3629 AT_SETUP([partial compressed data record])
3630 AT_KEYWORDS([sack synthetic system file positive])
3631 AT_DATA([sys-file.sack], [dnl
3633 "$FL2"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3635 6; dnl Nominal case size
3638 -1; dnl Unspecified number of cases.
3640 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
3643 dnl Numeric variables.
3644 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3645 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
3647 dnl String variable.
3648 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
3649 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
3650 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
3651 2; -1; 0; 0; 0; 0; s8 "";
3653 dnl Dictionary termination record.
3656 dnl Compressed data.
3657 i8 1 100 254 253 254 253; i8 255 251; "abcdefgh"; s8 "0123";
3660 "be ef01b16e2e397d979a3a7d20725ebe6d" \
3661 "le 51f7a61e9bc68992469d16c55d6ecd88"
3664 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3666 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3669 AT_CHECK([pspp -O format=csv sys-file.sps], [1],
3670 [error: `sys-file.sav' near offset 0x190: File ends in partial case.
3673 num1,num2,str4,str8,str15
3674 -99,0,,abcdefgh,0123 @&t@
3679 AT_SETUP([zcompressed data - bad zheader_ofs])
3680 AT_KEYWORDS([sack synthetic system file negative zlib])
3681 zcompressed_sack | sed 's/.*zheader_ofs.*/>>i64 0<<;/' > sys-file.sack
3683 "be 6d5c32f34fa1bed6f9b8f7045d104fdc" \
3684 "le 1f67fbda4f0021143e141fe8403c5a97"
3687 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3689 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3691 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x178: Wrong ZLIB data header offset 0 (expected 0x178).
3696 AT_SETUP([zcompressed data - bad ztrailer_ofs])
3697 AT_KEYWORDS([sack synthetic system file negative zlib])
3698 zcompressed_sack | sed 's/.*ztrailer_ofs.*/>>i64 0<<;/' > sys-file.sack
3700 "be e2c8dec0c62d3d798825ad5906370634" \
3701 "le c1cff4cdddeee80bf1580cbc26fa9fd5"
3704 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3706 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3708 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x178: Impossible ZLIB trailer offset 0x0.
3713 # ztrailer_len must be a multiple of 24 and at least 48,
3714 # so a value of 12 is impossible.
3715 AT_SETUP([zcompressed data - invalid ztrailer_len])
3716 AT_KEYWORDS([sack synthetic system file negative zlib])
3717 zcompressed_sack | sed 's/.*ztrailer_len.*/>>i64 12<<;/' > sys-file.sack
3719 "be 27f5203463bc4c7644382f24ae87f84c" \
3720 "le 0035fa6ee7690720429715150ede85f4"
3723 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3725 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3727 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x178: Invalid ZLIB trailer length 12.
3732 # ztrailer_ofs + ztrailer_len must be the file size.
3733 AT_SETUP([zcompressed data - wrong ztrailer_len])
3734 AT_KEYWORDS([sack synthetic system file negative zlib])
3735 zcompressed_sack | sed 's/.*ztrailer_len.*/>>i64 72<<;/' > sys-file.sack
3737 "be 2ba9ae97bc0a7f5dcfe36e2463b9d7cb" \
3738 "le d737ea0a53ca5c6f20be359027171d73"
3741 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3743 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3745 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [warning: `sys-file.sav' near offset 0x190: End of ZLIB trailer (0x231) is not file size (0x219).
3746 error: `sys-file.sav' near offset 0x201: 72-byte ZLIB trailer specifies 1 data blocks (expected 2).
3751 AT_SETUP([zcompressed data - wrong ztrailer_bias])
3752 AT_KEYWORDS([sack synthetic system file negative zlib])
3753 zcompressed_sack | sed 's/.*ztrailer_bias.*/>>i64 0<<;/' > sys-file.sack
3755 "be a5b56ab5e799a3626de2cdd7bd8d7a03" \
3756 "le d7cd584c6d5a95df10ba640eb3f1f24f"
3759 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3761 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3763 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x1f1: ZLIB trailer bias (0) differs from file header bias (100.00).
3768 AT_SETUP([zcompressed data - wrong ztrailer_zero])
3769 AT_KEYWORDS([sack synthetic system file negative zlib])
3770 zcompressed_sack | sed 's/.*ztrailer_zero.*/>>i64 100<<;/' > sys-file.sack
3772 "be 8d746abedb3e74cfdc22207f3455db92" \
3773 "le 79cea017365cab35d59c7a300cfa66c1"
3776 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3778 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3780 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0], [warning: `sys-file.sav' near offset 0x1f9: ZLIB trailer "zero" field has nonzero value 100.
3785 AT_SETUP([zcompressed data - wrong block_size])
3786 AT_KEYWORDS([sack synthetic system file negative zlib])
3787 zcompressed_sack | sed 's/.*block_size.*/>>0x1000<<;/' > sys-file.sack
3789 "be 8d5a1caa56be8892d453faf1047005ca" \
3790 "le 7daa1bd57b192893b313a351202e179b"
3793 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3795 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3797 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0], [warning: `sys-file.sav' near offset 0x1fd: ZLIB trailer specifies unexpected 4096-byte block size.
3802 AT_SETUP([zcompressed data - wrong n_blocks])
3803 AT_KEYWORDS([sack synthetic system file negative zlib])
3804 zcompressed_sack | sed 's/.*n_blocks.*/>>2<<;/' > sys-file.sack
3806 "be cd29596fd6bf4a2f651febe820a7955f" \
3807 "le 8fc1f718dfd2abac7c3442c1055d4cab"
3810 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3812 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3814 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x201: 48-byte ZLIB trailer specifies 2 data blocks (expected 1).
3819 AT_SETUP([zcompressed data - wrong uncompressed_ofs])
3820 AT_KEYWORDS([sack synthetic system file negative zlib])
3821 zcompressed_sack | sed 's/.*uncompressed_ofs.*/i64 >>0x177<<;/' > sys-file.sack
3823 "be 5546120fe6161dc6ed20aec48d8e74a4" \
3824 "le 86fafd625ed5ceaa1bff4fc7f500b6ab"
3827 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3829 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3831 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x201: ZLIB block descriptor 0 reported uncompressed data offset 0x177, when 0x178 was expected.
3836 AT_SETUP([zcompressed data - wrong compressed_ofs])
3837 AT_KEYWORDS([sack synthetic system file negative zlib])
3838 zcompressed_sack | sed 's/.*@%:@ compressed_ofs.*/i64 >>0x191<<;/' > sys-file.sack
3840 "be 652e28f8d3f8e4ce47ad18d0f30e7bb9" \
3841 "le ebf2c647f2d7c47858d4f5ed683526e6"
3844 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3846 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3848 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x201: ZLIB block descriptor 0 reported compressed data offset 0x191, when 0x190 was expected.
3853 AT_SETUP([zcompressed data - compressed sizes don't add up])
3854 AT_KEYWORDS([sack synthetic system file negative zlib])
3855 AT_DATA([sys-file.sack], [dnl
3857 "$FL3"; s60 "$(#) SPSS DATA FILE PSPP synthetic test file";
3859 6; dnl Nominal case size
3860 2; dnl zlib compressed
3862 -1; dnl Unspecified number of cases.
3864 "01 Jan 11"; "20:53:52"; s64 "PSPP synthetic test file";
3867 dnl Numeric variables.
3868 2; 0; 0; 0; 0x050800 *2; s8 "NUM1";
3869 2; 0; 0; 0; 0x050800 *2; s8 "NUM2";
3871 dnl String variable.
3872 2; 4; 0; 0; 0x010400 *2; s8 "STR4";
3873 2; 8; 0; 0; 0x010800 *2; s8 "STR8";
3874 2; 15; 0; 0; 0x010f00 *2; s8 "STR15";
3875 2; -1; 0; 0; 0; 0; s8 "";
3877 dnl Dictionary termination record.
3880 dnl ZLIB data header.
3881 i64 0x178; # zheader_ofs
3882 i64 0x190; # ztrailer_ofs
3883 i64 72; # ztrailer_len
3885 dnl This is where the ZLIB data blocks would go, but we don't need any to
3886 dnl provoke this message so we omit them.
3888 dnl ZLIB data trailer fixed header:
3889 i64 -100; # ztrailer_bias
3890 i64 0; # ztrailer_zero
3891 0x3ff000; # block_size
3894 dnl ZLIB block descriptor 1:
3895 i64 0x178; # uncompressed_ofs
3896 i64 0x190; # compressed_ofs
3897 0x100000; # uncompressed_size
3898 0x12345; # compressed_size
3900 dnl ZLIB block descriptor 2:
3901 i64 0x100178; # uncompressed_ofs
3902 i64 0x12405; # compressed_ofs
3903 0x100000; # uncompressed_size
3904 0x12345; # compressed_size
3907 "be 72ebf57bffa340afe16ed79959faac09" \
3908 "le 80b34e98f6b181dcc2e8ca4ba13f768d"
3911 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3913 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3915 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [warning: `sys-file.sav' near offset 0x1a8: ZLIB block descriptor 0 reported block size 0x100000, when 0x3ff000 was expected.
3916 error: `sys-file.sav' near offset 0x1c0: ZLIB block descriptor 1 reported compressed data offset 0x12405, when 0x124d5 was expected.
3921 AT_SETUP([zcompressed data - uncompressed_size > block_size])
3922 AT_KEYWORDS([sack synthetic system file negative zlib])
3923 zcompressed_sack | sed 's/.*uncompressed_size.*/>>0x400000<<;/' > sys-file.sack
3925 "be 9bb74ef407fe0b79e43c388eedc28212" \
3926 "le 6f145fb5f820c513f50b6f81310cdad5"
3929 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3931 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3933 AT_CHECK([pspp -o pspp.csv sys-file.sps], [0], [warning: `sys-file.sav' near offset 0x201: ZLIB block descriptor 0 reported block size 0x400000, when at most 0x3ff000 was expected.
3938 AT_SETUP([zcompressed data - compression expands data too much])
3939 AT_KEYWORDS([sack synthetic system file negative zlib])
3940 zcompressed_sack | sed 's/.*uncompressed_size.*/>>50<<;/
3941 s/.*@%:@ compressed_size.*/>>100<<;/' > sys-file.sack
3943 "be e11cadde5f0855c965a1cb388dedc36e" \
3944 "le 37953e71462b6554c5644fec8b539164"
3947 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3949 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3951 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x201: ZLIB block descriptor 0 reports compressed size 100 and uncompressed size 50.
3956 AT_SETUP([zcompressed data - compressed sizes don't add up])
3957 AT_KEYWORDS([sack synthetic system file negative zlib])
3958 zcompressed_sack | sed 's/.*@%:@ compressed_size.*/>>88<<;/' > sys-file.sack
3960 "be 366eaf85be1f26fb6549e2f8ee393628" \
3961 "le a756e5125e6a908cb4990f66cc419bef"
3964 AT_CHECK_UNQUOTED([sack --$[1] sys-file.sack > sys-file.sav], [0], [], [$[2]
3966 AT_DATA([sys-file.sps], [GET FILE='sys-file.sav'.
3968 AT_CHECK([pspp -o pspp.csv sys-file.sps], [1], [error: `sys-file.sav' near offset 0x219: ZLIB trailer is at offset 0x1e9 but 0x1e8 would be expected from block descriptors.