1 dnl PSPP - a program for statistical analysis.
2 dnl Copyright (C) 2017 Free Software Foundation, Inc.
4 dnl This program is free software: you can redistribute it and/or modify
5 dnl it under the terms of the GNU General Public License as published by
6 dnl the Free Software Foundation, either version 3 of the License, or
7 dnl (at your option) any later version.
9 dnl This program is distributed in the hope that it will be useful,
10 dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
11 dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 dnl GNU General Public License for more details.
14 dnl You should have received a copy of the GNU General Public License
15 dnl along with this program. If not, see <http://www.gnu.org/licenses/>.
29 m4_define([WEAVE_6X6],
74 m4_define([WEAVE_8X8],
128 # This input is something of a counterexample, in that it could render
129 # compactly as this if the algorithm for choosing cell widths and
130 # heights were smarter:
149 m4_define([WEAVE_8X8_2],
169 2*3 @MNOPQ\nRSTUV\nWXYZ0
174 AT_BANNER([output rendering -- no page breaking])
176 AT_SETUP([single cell])
177 AT_KEYWORDS([render rendering])
178 AT_DATA([input], [1 1
181 AT_CHECK([render-test input], [0], [abc
185 AT_SETUP([single cell with border])
186 AT_KEYWORDS([render rendering])
187 AT_DATA([input], [1 1
190 AT_CHECK([render-test input], [0], [dnl
197 AT_SETUP([joined columns])
198 AT_KEYWORDS([render rendering])
199 AT_DATA([input], [2 2
204 AT_CHECK([render-test input], [0], [dnl
213 AT_SETUP([3x3, joined rows and columns])
214 AT_KEYWORDS([render rendering])
215 AT_DATA([input], [3 3
222 AT_CHECK([render-test input], [0], [dnl
233 AT_SETUP([joined rows and columns (with footnotes)])
234 AT_KEYWORDS([render rendering footnote])
235 AT_DATA([input], [3 3
236 1*2 @abc#Approximation.
237 2*1 @d\ne\nf#This is a very long footnote that will have to wrap from one line to the next. Let's see if the rendering engine does it acceptably.
238 2*1 @g\nh\ni#One#Two#Three
242 AT_CHECK([render-test --csv input], [0],
243 [[+------------+----+
251 [b] This is a very long footnote that will have to wrap from one line to the
252 next. Let's see if the rendering engine does it acceptably.
257 AT_CHECK([cat render.csv], [0],
268 b,This is a very long footnote that will have to wrap from one line to the next. Let's see if the rendering engine does it acceptably.
275 AT_SETUP([6x6, joined rows and columns])
276 AT_KEYWORDS([render rendering])
277 AT_DATA([input], [WEAVE_6X6])
278 AT_CHECK([render-test input], [0], [dnl
295 AT_SETUP([3 rows with many joined cells])
296 AT_KEYWORDS([render rendering])
297 AT_CAPTURE_FILE([input])
298 AT_DATA([input], [3 19
299 m4_foreach([x], [a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s], [x
301 m4_for([x], [2], [19], [1], [1*2 @x
304 AT_CHECK([render-test input], [0], [dnl
305 a b c d e f g h i j k l m n o p q r s
306 +-+---+---+---+---+---+---+---+---+----+
307 |1| 2| 3| 4| 5| 6| 7| 8| 9| 10|
308 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+--+
309 | 11| 12| 13| 14| 15| 16| 17| 18| 19|20|
310 +---+---+---+---+---+---+---+---+---+--+
314 AT_SETUP([3 columns with many joined cells])
315 AT_KEYWORDS([render rendering])
316 AT_CAPTURE_FILE([input])
317 AT_DATA([input], [3 19
318 m4_foreach([x], [a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s], [x
320 m4_for([x], [2], [19], [1], [1*2 @x\nab\ncd
323 AT_CHECK([render-test --transpose input], [0], [dnl
366 AT_SETUP([joined rows])
367 AT_KEYWORDS([render rendering])
368 AT_DATA([input], [2 2
373 AT_CHECK([render-test input], [0], [dnl
382 dnl This checks for bug #31346, a segmentation fault that surfaced
383 dnl when two or more rows had no unspanned cells and no rules.
384 AT_SETUP([joined rows only, no rules])
385 AT_KEYWORDS([render rendering])
386 AT_DATA([input], [2 2
390 AT_CHECK([render-test input], [0], [dnl
397 AT_SETUP([joined columns only, no rules])
398 AT_KEYWORDS([render rendering])
399 AT_DATA([input], [2 2
403 AT_CHECK([render-test input], [0], [dnl
412 AT_SETUP([5 big narrow cells])
413 AT_KEYWORDS([render rendering])
414 AT_DATA([input], [1 5
415 @This cell has a lot of text but its minimum width is pretty narrow.
416 @This cell also has a lot of text but its minimum width is pretty narrow.
417 @A third cell with a lot of text but a pretty narrow minimum width.
418 @A fourth cell with a lot of text but a pretty narrow minimum width.
419 @A fifth cell with a lot of text but a pretty narrow minimum width.
421 AT_CHECK([render-test input], [0], [dnl
422 +---------------+---------------+--------------+---------------+--------------+
423 |This cell has a| This cell also| A third cell| A fourth cell| A fifth cell|
424 |lot of text but| has a lot of| with a lot of| with a lot of| with a lot of|
425 | its minimum| text but its| text but a| text but a| text but a|
426 |width is pretty| minimum width| pretty narrow| pretty narrow| pretty narrow|
427 | narrow.| is pretty|minimum width.| minimum width.|minimum width.|
429 +---------------+---------------+--------------+---------------+--------------+
433 AT_SETUP([9 big narrow cells])
434 AT_KEYWORDS([render rendering])
435 AT_DATA([input], [1 9
436 @This cell has a lot of text but its minimum width is pretty narrow.
437 @This cell also has a lot of text but its minimum width is pretty narrow.
438 @A third cell with a lot of text but a pretty narrow minimum width.
439 @A fourth cell with a lot of text but a pretty narrow minimum width.
440 @A fifth cell with a lot of text but a pretty narrow minimum width.
441 @A sixth cell with a lot of text but a pretty narrow minimum width.
442 @A seventh cell with a lot of text but a pretty narrow minimum width.
443 @A eighth cell with a lot of text but a pretty narrow minimum width.
444 @A ninth cell with a lot of text but a pretty narrow minimum width.
446 AT_CHECK([render-test input], [0], [dnl
447 +--------+-------+--------+--------+-------+--------+--------+-------+--------+
448 | This| This| A third|A fourth|A fifth| A sixth| A| A| A ninth|
449 |cell has| cell| cell| cell| cell| cell| seventh| eighth| cell|
450 |a lot of| also| with a| with a| with a| with a| cell| cell| with a|
451 |text but| has a| lot of| lot of| lot of| lot of| with a| with a| lot of|
452 | its| lot of|text but|text but| text|text but| lot of| lot of|text but|
453 | minimum| text|a pretty|a pretty| but a|a pretty|text but| text|a pretty|
454 |width is|but its| narrow| narrow| pretty| narrow|a pretty| but a| narrow|
455 | pretty|minimum| minimum| minimum| narrow| minimum| narrow| pretty| minimum|
456 | narrow.| width| width.| width.|minimum| width.| minimum| narrow| width.|
457 | | is| | | width.| | width.|minimum| |
458 | | pretty| | | | | | width.| |
459 | |narrow.| | | | | | | |
460 +--------+-------+--------+--------+-------+--------+--------+-------+--------+
464 AT_SETUP([2 big cells with new-lines])
465 AT_KEYWORDS([render rendering])
466 AT_DATA([input], [1 2
467 @PSPP does not place many restrictions on ordering of commands. The main restriction is that variables must be defined before they are otherwise referenced. This section describes the details of command ordering, but most users will have no need to refer to them. PSPP possesses five internal states, called initial, INPUT PROGRAM, FILE TYPE, transformation, and procedure states.
468 @PSPP includes special support\nfor unknown numeric data values.\nMissing observations are assigned\na special value, called the\n``system‑missing value''. This\n``value'' actually indicates the\nabsence of a value; it\nmeans that the actual\nvalue is unknown.
470 AT_CHECK([render-test input], [0], [dnl
471 +----------------------------------------------------------+------------------+
472 | PSPP does not place many restrictions on ordering of| PSPP includes|
473 | commands. The main restriction is that variables must be| special support|
474 | defined before they are otherwise referenced. This| for unknown|
475 | section describes the details of command ordering, but| numeric data|
476 | most users will have no need to refer to them. PSPP| values.|
477 | possesses five internal states, called initial, INPUT| Missing|
478 | PROGRAM, FILE TYPE, transformation, and procedure states.| observations are|
480 | | a special value,|
482 | | ``system‑missing|
484 | |``value'' actually|
490 | | value is unknown.|
491 +----------------------------------------------------------+------------------+
495 AT_SETUP([8x8 with many 2x2 joins])
496 AT_KEYWORDS([render rendering])
497 AT_DATA([input], [WEAVE_8X8_2])
498 AT_CHECK([render-test input], [0],[dnl
524 AT_BANNER([output rendering -- horizontal page breaks])
526 AT_SETUP([breaking row of many small cells])
527 AT_KEYWORDS([render rendering])
528 AT_CAPTURE_FILE([input])
529 AT_DATA([input], [1 50
530 m4_for([x], [1], [50], [1], [@x
532 AT_CHECK([render-test input], [0], [dnl
533 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
534 |1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|
535 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
537 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
538 |30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49|50|
539 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
541 AT_CHECK([render-test input -o mb0 --min-break=0], [0], [dnl
542 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
543 |1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|
544 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
546 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
547 |30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49|50|
548 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
552 AT_SETUP([breaking row of many small cells, with headers])
553 AT_KEYWORDS([render rendering])
554 AT_CAPTURE_FILE([input])
555 AT_DATA([input], [1 54 2 2
558 m4_for([x], [1], [50], [1], [@x
563 AT_CHECK([render-test input], [0], [dnl
564 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
565 |ha|hb|1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|hc|hd|
566 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
568 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
569 |ha|hb|26|27|28|29|30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|hc|hd|
570 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
572 +--+--+--+--+--+--+--+
573 |ha|hb|48|49|50|hc|hd|
574 +--+--+--+--+--+--+--+
576 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
577 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
578 |ha|hb|1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|hc|hd|
579 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
581 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
582 |ha|hb|26|27|28|29|30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|hc|hd|
583 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
585 +--+--+--+--+--+--+--+
586 |ha|hb|48|49|50|hc|hd|
587 +--+--+--+--+--+--+--+
591 AT_SETUP([breaking row of many medium-size cells])
592 AT_KEYWORDS([render rendering])
593 AT_CAPTURE_FILE([input])
594 AT_DATA([input], [1 50
595 m4_for([x], [1], [50], [1], [@cell x
597 AT_CHECK([render-test input], [0], [dnl
598 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
599 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|
600 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15|
601 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
603 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
604 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|
605 | 16| 17| 18| 19| 20| 21| 22| 23| 24| 25| 26| 27| 28| 29| 30|
606 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
608 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
609 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|
610 | 31| 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 45|
611 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
613 +----+----+----+----+----+
614 |cell|cell|cell|cell|cell|
615 | 46| 47| 48| 49| 50|
616 +----+----+----+----+----+
618 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
619 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+---
620 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cel
621 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15| 1
622 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+---
624 -+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+--
625 l|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|ce
626 6| 17| 18| 19| 20| 21| 22| 23| 24| 25| 26| 27| 28| 29| 30| 31|
627 -+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+--
629 --+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+-
630 ll|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|c
631 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 45| 46| 47|
632 --+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+-
641 AT_SETUP([breaking row of many medium-size cells, with headers])
642 AT_KEYWORDS([render rendering])
643 AT_CAPTURE_FILE([input])
644 AT_DATA([input], [1 52 1 1
646 m4_for([x], [1], [50], [1], [@cell x
650 AT_CHECK([render-test input], [0], [dnl
651 +----+----+----+----+----+----+----+----+----+----+----+----+
652 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
653 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12|
654 +----+----+----+----+----+----+----+----+----+----+----+----+
656 +----+----+----+----+----+----+----+----+----+----+----+----+
657 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
658 | 13| 14| 15| 16| 17| 18| 19| 20| 21| 22| 23| 24|
659 +----+----+----+----+----+----+----+----+----+----+----+----+
661 +----+----+----+----+----+----+----+----+----+----+----+----+
662 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
663 | 25| 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36|
664 +----+----+----+----+----+----+----+----+----+----+----+----+
666 +----+----+----+----+----+----+----+----+----+----+----+----+
667 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
668 | 37| 38| 39| 40| 41| 42| 43| 44| 45| 46| 47| 48|
669 +----+----+----+----+----+----+----+----+----+----+----+----+
672 header1|cell|cell|header2
676 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
677 +----+----+----+----+----+----+----+----+----+----+----+----+--+
678 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|ce|header2
679 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| |
680 +----+----+----+----+----+----+----+----+----+----+----+----+--+
682 +--+----+----+----+----+----+----+----+----+----+----+----+----+
683 header1|ll|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
684 |13| 14| 15| 16| 17| 18| 19| 20| 21| 22| 23| 24| 25|
685 +--+----+----+----+----+----+----+----+----+----+----+----+----+
687 +----+----+----+----+----+----+----+----+----+----+----+----+--+
688 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|ce|header2
689 | 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36| 37| |
690 +----+----+----+----+----+----+----+----+----+----+----+----+--+
692 +--+----+----+----+----+----+----+----+----+----+----+----+----+
693 header1|ll|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
694 |38| 39| 40| 41| 42| 43| 44| 45| 46| 47| 48| 49| 50|
695 +--+----+----+----+----+----+----+----+----+----+----+----+----+
699 AT_SETUP([breaking row of many big narrow cells])
700 AT_KEYWORDS([render rendering])
701 AT_CAPTURE_FILE([input])
702 AT_DATA([input], [1 50
703 m4_for([x], [1], [50], [1], [@This is cell x in a series of 50.
705 AT_CHECK([render-test input], [0], [dnl
706 +------+------+------+------+------+------+------+------+------+------+------+
707 | This| This| This| This| This| This| This| This| This| This| This|
708 | is| is| is| is| is| is| is| is| is| is| is|
709 |cell 1|cell 2|cell 3|cell 4|cell 5|cell 6|cell 7|cell 8|cell 9| cell| cell|
710 | in a| in a| in a| in a| in a| in a| in a| in a| in a| 10 in| 11 in|
711 |series|series|series|series|series|series|series|series|series| a| a|
712 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|series|series|
713 | | | | | | | | | |of 50.|of 50.|
714 +------+------+------+------+------+------+------+------+------+------+------+
716 +------+------+------+------+------+------+------+------+------+------+------+
717 | This| This| This| This| This| This| This| This| This| This| This|
718 | is| is| is| is| is| is| is| is| is| is| is|
719 | cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
720 | 12 in| 13 in| 14 in| 15 in| 16 in| 17 in| 18 in| 19 in| 20 in| 21 in| 22 in|
721 | a| a| a| a| a| a| a| a| a| a| a|
722 |series|series|series|series|series|series|series|series|series|series|series|
723 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
724 +------+------+------+------+------+------+------+------+------+------+------+
726 +------+------+------+------+------+------+------+------+------+------+------+
727 | This| This| This| This| This| This| This| This| This| This| This|
728 | is| is| is| is| is| is| is| is| is| is| is|
729 | cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
730 | 23 in| 24 in| 25 in| 26 in| 27 in| 28 in| 29 in| 30 in| 31 in| 32 in| 33 in|
731 | a| a| a| a| a| a| a| a| a| a| a|
732 |series|series|series|series|series|series|series|series|series|series|series|
733 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
734 +------+------+------+------+------+------+------+------+------+------+------+
736 +------+------+------+------+------+------+------+------+------+------+------+
737 | This| This| This| This| This| This| This| This| This| This| This|
738 | is| is| is| is| is| is| is| is| is| is| is|
739 | cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
740 | 34 in| 35 in| 36 in| 37 in| 38 in| 39 in| 40 in| 41 in| 42 in| 43 in| 44 in|
741 | a| a| a| a| a| a| a| a| a| a| a|
742 |series|series|series|series|series|series|series|series|series|series|series|
743 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
744 +------+------+------+------+------+------+------+------+------+------+------+
746 +------+------+------+------+------+------+
747 | This| This| This| This| This| This|
748 | is| is| is| is| is| is|
749 | cell| cell| cell| cell| cell| cell|
750 | 45 in| 46 in| 47 in| 48 in| 49 in| 50 in|
752 |series|series|series|series|series|series|
753 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
754 +------+------+------+------+------+------+
756 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
757 +------+------+------+------+------+------+------+------+------+------+------+-
758 | This| This| This| This| This| This| This| This| This| This| This|
759 | is| is| is| is| is| is| is| is| is| is| is|
760 |cell 1|cell 2|cell 3|cell 4|cell 5|cell 6|cell 7|cell 8|cell 9| cell| cell|
761 | in a| in a| in a| in a| in a| in a| in a| in a| in a| 10 in| 11 in|
762 |series|series|series|series|series|series|series|series|series| a| a|
763 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|series|series|s
764 | | | | | | | | | |of 50.|of 50.|o
765 +------+------+------+------+------+------+------+------+------+------+------+-
767 -----+------+------+------+------+------+------+------+------+------+------+---
768 This| This| This| This| This| This| This| This| This| This| This| T
769 is| is| is| is| is| is| is| is| is| is| is|
770 cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| c
771 12 in| 13 in| 14 in| 15 in| 16 in| 17 in| 18 in| 19 in| 20 in| 21 in| 22 in| 23
772 a| a| a| a| a| a| a| a| a| a| a|
773 eries|series|series|series|series|series|series|series|series|series|series|ser
774 f 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of
775 -----+------+------+------+------+------+------+------+------+------+------+---
777 ---+------+------+------+------+------+------+------+------+------+------+-----
778 his| This| This| This| This| This| This| This| This| This| This| Thi
779 is| is| is| is| is| is| is| is| is| is| is| i
780 ell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cel
781 in| 24 in| 25 in| 26 in| 27 in| 28 in| 29 in| 30 in| 31 in| 32 in| 33 in| 34 i
782 a| a| a| a| a| a| a| a| a| a| a|
783 ies|series|series|series|series|series|series|series|series|series|series|serie
784 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50
785 ---+------+------+------+------+------+------+------+------+------+------+-----
787 -+------+------+------+------+------+------+------+------+------+------+------+
788 s| This| This| This| This| This| This| This| This| This| This| This|
789 s| is| is| is| is| is| is| is| is| is| is| is|
790 l| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
791 n| 35 in| 36 in| 37 in| 38 in| 39 in| 40 in| 41 in| 42 in| 43 in| 44 in| 45 in|
792 a| a| a| a| a| a| a| a| a| a| a| a|
793 s|series|series|series|series|series|series|series|series|series|series|series|
794 .|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
795 -+------+------+------+------+------+------+------+------+------+------+------+
797 +------+------+------+------+------+
798 | This| This| This| This| This|
799 | is| is| is| is| is|
800 | cell| cell| cell| cell| cell|
801 | 46 in| 47 in| 48 in| 49 in| 50 in|
803 |series|series|series|series|series|
804 |of 50.|of 50.|of 50.|of 50.|of 50.|
805 +------+------+------+------+------+
809 AT_SETUP([breaking 2 rows of many small cells])
810 AT_KEYWORDS([render rendering])
811 AT_CAPTURE_FILE([input])
812 AT_DATA([input], [2 50
813 m4_for([x], [1], [100], [1], [@x
815 AT_CHECK([render-test input], [0], [dnl
816 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
817 | 1| 2| 3| 4| 5| 6| 7| 8| 9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|
818 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
819 |51|52|53|54|55|56|57|58|59|60|61|62|63|64|65|66|67|68|69|70|71|72|73|74|75|76|
820 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
822 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
823 |27|28|29|30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49| 50|
824 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
825 |77|78|79|80|81|82|83|84|85|86|87|88|89|90|91|92|93|94|95|96|97|98|99|100|
826 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
828 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
829 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
830 | 1| 2| 3| 4| 5| 6| 7| 8| 9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|
831 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
832 |51|52|53|54|55|56|57|58|59|60|61|62|63|64|65|66|67|68|69|70|71|72|73|74|75|76|
833 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
835 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
836 |27|28|29|30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49| 50|
837 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
838 |77|78|79|80|81|82|83|84|85|86|87|88|89|90|91|92|93|94|95|96|97|98|99|100|
839 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
843 AT_SETUP([breaking 3 rows with many joined cells])
844 AT_KEYWORDS([render rendering])
845 AT_CAPTURE_FILE([input])
846 AT_DATA([input], [3 49
847 m4_foreach([var], [a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,dnl
848 A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W], [var
850 m4_for([x], [2], [49], [1], [1*2 @x
853 AT_CHECK([render-test input], [0], [dnl
854 a b c d e f g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M
855 +-+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
856 |1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15| 16| 17| 18| 19| 20|
857 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
858 | 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 4
859 +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+--
862 +---+---+---+---+----+
863 | 21| 22| 23| 24| 25|
864 +-+-+-+-+-+-+-+-+-+--+
865 45| 46| 47| 48| 49|50|
866 --+---+---+---+---+--+
868 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
869 a b c d e f g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M
870 +-+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
871 |1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15| 16| 17| 18| 19| 20|
872 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
873 | 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 4
874 +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+--
877 +---+---+---+---+----+
878 | 21| 22| 23| 24| 25|
879 +-+-+-+-+-+-+-+-+-+--+
880 45| 46| 47| 48| 49|50|
881 --+---+---+---+---+--+
885 AT_SETUP([horz break 6x6, joined rows and columns])
886 AT_KEYWORDS([render rendering])
887 AT_DATA([input], [WEAVE_6X6])
888 AT_DATA([expout], [dnl
931 AT_CHECK([render-test --width=6 input], [0], [expout])
932 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [expout])
935 AT_SETUP([horz break 6x6, joined rows and columns, left header])
936 AT_KEYWORDS([render rendering])
937 AT_DATA([input], [WEAVE_6X6([1 0 0 0])])
938 AT_DATA([expout], [dnl
967 AT_CHECK([render-test --width=10 input], [0], [expout])
968 AT_CHECK([render-test -o mb0 --min-break=0 --width=10 input], [0], [expout])
971 AT_SETUP([horz break 6x6, joined rows and columns, right header])
972 AT_KEYWORDS([render rendering])
973 AT_DATA([input], [WEAVE_6X6([0 1 0 0])])
974 AT_DATA([expout], [dnl
1003 AT_CHECK([render-test --width=10 input], [0], [expout])
1004 AT_CHECK([render-test -o mb0 --min-break=0 --width=10 input], [0], [expout])
1007 AT_SETUP([breaking joined cells too wide for page])
1008 AT_KEYWORDS([render rendering])
1009 AT_DATA([input], [4 6
1010 1*6 @abc def ghi jkl
1023 AT_CHECK([render-test --width=10 input], [0], [dnl
1048 AT_CHECK([render-test -o mb0 --min-break=0 --width=10 input], [0], [dnl
1075 AT_SETUP([breaking joined cells much too wide for page])
1076 AT_KEYWORDS([render rendering])
1077 AT_DATA([input], [4 6
1078 1*6 @abc def ghi jkl
1091 AT_CHECK([render-test --width=6 input], [0], [dnl
1128 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [dnl
1167 AT_SETUP([breaking cell too wide for page, no border])
1168 AT_KEYWORDS([render rendering])
1169 AT_CAPTURE_FILE([input])
1170 AT_DATA([input], [1 1
1171 abcdefghijklmnopqrstuvwxyz
1173 AT_CHECK([render-test --width=6 input], [0], [dnl
1184 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [dnl
1197 AT_SETUP([breaking cell too wide for page, with border])
1198 AT_KEYWORDS([render rendering])
1199 AT_CAPTURE_FILE([input])
1200 AT_DATA([input], [1 1
1201 @abcdefghijklmnopqrstuvwxyz
1203 AT_DATA([expout], [dnl
1224 AT_CHECK([render-test --width=6 input], [0], [expout])
1225 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [expout])
1228 AT_SETUP([horz break 8x8 with many 2x2 joins])
1229 AT_KEYWORDS([render rendering])
1230 AT_DATA([input], [WEAVE_8X8_2])
1231 AT_CHECK([render-test --width=8 input], [0],[dnl
1303 AT_CHECK([render-test -o mb0 --min-break=0 --width=8 input], [0],[dnl
1376 AT_BANNER([output rendering -- vertical page breaks])
1378 AT_SETUP([breaking column of many small cells])
1379 AT_KEYWORDS([render rendering])
1380 AT_CAPTURE_FILE([input])
1381 AT_DATA([input], [20 1
1382 m4_for([x], [1], [20], [1], [@x
1384 AT_CHECK([render-test --length=10 input], [0], [dnl
1435 AT_CHECK([render-test -o mb0 --min-break=0 --length=10 input], [0], [dnl
1488 AT_SETUP([breaking column of many small cells, with headers])
1489 AT_KEYWORDS([render rendering])
1490 AT_CAPTURE_FILE([input])
1491 AT_DATA([input], [17 1 0 0 1 1
1493 m4_for([x], [1], [15], [1], [@x
1496 AT_CHECK([render-test --length=13 input], [0], [dnl
1551 AT_CHECK([render-test -o mb0 --min-break=0 --length=13 input], [0], [dnl
1608 AT_SETUP([disabling too-big headers])
1609 AT_KEYWORDS([render rendering])
1610 AT_CAPTURE_FILE([input])
1611 AT_DATA([input], [17 1 0 0 1 1
1613 m4_for([x], [1], [15], [1], [@x
1616 AT_DATA([expout], [dnl
1661 AT_CHECK([render-test --length=10 input], [0], [expout])
1662 AT_CHECK([render-test -o mb0 --min-break=0 --length=10 input], [0], [expout])
1665 AT_SETUP([breaking column of many medium-size cells])
1666 AT_KEYWORDS([render rendering])
1667 AT_CAPTURE_FILE([input])
1668 AT_DATA([input], [20 1
1669 m4_for([x], [1], [20], [1], [@top x\ncell x\nbottom x
1671 AT_CHECK([render-test --length 10 input], [0], [dnl
1772 AT_CHECK([render-test -o mb0 --min-break=0 --length 10 input], [0], [dnl
1867 AT_SETUP([breaking 3 columns with many joined cells])
1868 AT_KEYWORDS([render rendering])
1869 AT_CAPTURE_FILE([input])
1909 AT_DATA([input], [3 19
1910 m4_foreach([x], [a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s], [x
1912 m4_for([x], [2], [19], [1], [1*2 @x\nab\ncd
1915 AT_DATA([expout], [dnl
1974 AT_CHECK([render-test --length=6 --transpose input], [0], [expout])
1975 AT_CHECK([render-test -o mb0 --min-break=0 --length=6 --transpose input],
1979 AT_SETUP([vert break 6x6, joined rows and columns])
1980 AT_KEYWORDS([render rendering])
1981 AT_DATA([input], [WEAVE_6X6])
1982 AT_CHECK([render-test --length=6 input], [0], [dnl
2001 AT_CHECK([render-test -o mb0 --min-break=0 --length=6 input], [0], [dnl
2022 AT_SETUP([breaking joined cells too tall for page])
2023 AT_KEYWORDS([render rendering])
2024 AT_DATA([input], [4 6
2025 1*6 @abc\ndef\nghi\njkl\nmno\npqr\nstu\nvwx\nyzA\nBCD\nEFG
2026 1*3 @HIJ\nKLM\nOPQ\nRST\nUVW
2027 1*3 @XYZ\n012\n345\n678\n90a
2038 AT_CHECK([render-test --transpose --length=6 input], [0], [dnl
2057 AT_CHECK([render-test -o mb0 --min-break=0 --transpose --length=6 input], [0], [dnl
2078 AT_SETUP([breaking cell too tall for page, no border])
2079 AT_KEYWORDS([render rendering])
2080 AT_CAPTURE_FILE([input])
2081 AT_DATA([input], [1 1
2082 abc defg hij klmn opq rstu vwx yz ABCDE FGH I JK LMNOP QR STU VWXYZ
2084 AT_CHECK([render-test --width=6 --length=6 input], [0], [dnl
2101 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 --length=6 input], [0], [dnl
2120 AT_SETUP([breaking cell too tall for page, with border])
2121 AT_KEYWORDS([render rendering])
2122 AT_CAPTURE_FILE([input])
2123 AT_DATA([input], [1 1
2124 @abc defg hij klmn opq rstu vwx yz ABCDE FGH I JK LMNOP QR STU VWXYZ
2126 AT_DATA([expout], [dnl
2147 AT_CHECK([render-test --width=7 --length=6 input], [0], [expout])
2148 AT_CHECK([render-test -o mb0 --min-break=0 --width=7 --length=6 input],
2152 AT_BANNER([output rendering -- double page breaks])
2154 AT_SETUP([double break 6x6, joined rows and columns])
2155 AT_KEYWORDS([render rendering])
2156 AT_DATA([input], [WEAVE_6X6])
2157 AT_CHECK([render-test --width=6 --length=6 input], [0], [dnl
2212 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 --length=6 input], [0], [dnl
2269 AT_SETUP([double break 8x8, with joins, left and right headers])
2270 AT_KEYWORDS([render rendering])
2271 AT_DATA([input], [WEAVE_8X8([1 1 0 0])])
2272 AT_CHECK([render-test input --width=14 --length=14], [0], [dnl
2313 AT_CHECK([render-test -o mb0 --min-break=0 input --width=14 --length=14], [0], [dnl
2356 AT_SETUP([double break 8x8, with joins, top and bottom headers])
2357 AT_KEYWORDS([render rendering])
2358 AT_DATA([input], [WEAVE_8X8([0 0 1 1])])
2359 AT_CHECK([render-test input --width=14 --length=14], [0], [dnl
2410 AT_CHECK([render-test -o mb0 --min-break=0 input --width=14 --length=14], [0], [dnl
2463 AT_SETUP([double break 8x8, with joins, all headers])
2464 AT_KEYWORDS([render rendering])
2465 AT_DATA([input], [WEAVE_8X8([1 1 1 1])])
2466 AT_CHECK([render-test input --width=14 --length=14], [0], [dnl
2517 AT_CHECK([render-test -o mb0 --min-break=0 input --width=14 --length=14], [0], [dnl
2570 AT_SETUP([double break joined cells too big for page])
2571 AT_KEYWORDS([render rendering])
2572 AT_DATA([input], [7 7
2581 6*6 @The MISSING subcommand determines the handling of missing variables. If INCLUDE is set, then user‑missing values are included in the calculations. If NOINCLUDE is set, which is the default, user‑missing values are excluded.
2588 AT_CHECK([render-test --width=15 --length=15 input], [0], [dnl
2645 AT_CHECK([render-test -o mb0 --min-break=0 --width=15 --length=15 input], [0], [dnl
2703 AT_BANNER([output rendering -- problematic procedures])
2705 dnl LIST used to put columns right up next to each other without any
2706 dnl intervening space, so this checks for regression.
2707 AT_SETUP([LIST puts space between columns])
2708 AT_KEYWORDS([render rendering])
2709 AT_DATA([list.sps], [dnl
2710 DATA LIST LIST NOTABLE /x y z (F1.0).
2718 AT_CHECK([pspp list.sps], [0], [dnl
2728 # Long string variables tend to end in lots of spaces. The ASCII
2729 # driver didn't handle this very well: it would essentially produce
2730 # one blank line in a cell for each trailing space. This test
2731 # checks for regression. See bug #38672.
2732 AT_SETUP([ASCII driver renders end of line spaces reasonably])
2733 AT_KEYWORDS([render rendering])
2734 AT_DATA([input], [dnl
2746 AT_CHECK([render-test --width=15 --length=15 input], [0], [dnl
2757 # There was a bug that, when multiple cells spanned a single column
2758 # (or row), only the dimensions of the cell nearest the bottom of the
2759 # table were actually considered. This checks for regression. (This
2760 # problem was most easily observed with SYSFILE INFO, which uses lots
2761 # of spanned cells).
2763 # Without the fix, the output looks like this:
2770 AT_SETUP([multiple spanned cells all contribute to dimensions])
2771 AT_KEYWORDS([render rendering])
2772 AT_DATA([input], [dnl
2774 1*2 @A long text string.
2777 AT_CHECK([render-test --width=30 --length=15 input], [0], [dnl
2778 +-------------------+
2779 |A long text string.|
2780 +-------------------+
2782 +-------------------+