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],
265 Footnote: a. Approximation.
266 Footnote: 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.
273 AT_SETUP([6x6, joined rows and columns])
274 AT_KEYWORDS([render rendering])
275 AT_DATA([input], [WEAVE_6X6])
276 AT_CHECK([render-test input], [0], [dnl
293 AT_SETUP([3 rows with many joined cells])
294 AT_KEYWORDS([render rendering])
295 AT_CAPTURE_FILE([input])
296 AT_DATA([input], [3 19
297 m4_foreach([x], [a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s], [x
299 m4_for([x], [2], [19], [1], [1*2 @x
302 AT_CHECK([render-test input], [0], [dnl
303 a b c d e f g h i j k l m n o p q r s
304 +-+---+---+---+---+---+---+---+---+----+
305 |1| 2| 3| 4| 5| 6| 7| 8| 9| 10|
306 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+--+
307 | 11| 12| 13| 14| 15| 16| 17| 18| 19|20|
308 +---+---+---+---+---+---+---+---+---+--+
312 AT_SETUP([3 columns with many joined cells])
313 AT_KEYWORDS([render rendering])
314 AT_CAPTURE_FILE([input])
315 AT_DATA([input], [19 3
356 AT_CHECK([render-test input], [0], [dnl
399 AT_SETUP([joined rows])
400 AT_KEYWORDS([render rendering])
401 AT_DATA([input], [2 2
406 AT_CHECK([render-test input], [0], [dnl
415 dnl This checks for bug #31346, a segmentation fault that surfaced
416 dnl when two or more rows had no unspanned cells and no rules.
417 AT_SETUP([joined rows only, no rules])
418 AT_KEYWORDS([render rendering])
419 AT_DATA([input], [2 2
423 AT_CHECK([render-test input], [0], [dnl
430 AT_SETUP([joined columns only, no rules])
431 AT_KEYWORDS([render rendering])
432 AT_DATA([input], [2 2
436 AT_CHECK([render-test input], [0], [dnl
445 AT_SETUP([5 big narrow cells])
446 AT_KEYWORDS([render rendering])
447 AT_DATA([input], [1 5
448 @This cell has a lot of text but its minimum width is pretty narrow.
449 @This cell also has a lot of text but its minimum width is pretty narrow.
450 @A third cell with a lot of text but a pretty narrow minimum width.
451 @A fourth cell with a lot of text but a pretty narrow minimum width.
452 @A fifth cell with a lot of text but a pretty narrow minimum width.
454 AT_CHECK([render-test input], [0], [dnl
455 +---------------+---------------+--------------+---------------+--------------+
456 |This cell has a| This cell also| A third cell| A fourth cell| A fifth cell|
457 |lot of text but| has a lot of| with a lot of| with a lot of| with a lot of|
458 | its minimum| text but its| text but a| text but a| text but a|
459 |width is pretty| minimum width| pretty narrow| pretty narrow| pretty narrow|
460 | narrow.| is pretty|minimum width.| minimum width.|minimum width.|
462 +---------------+---------------+--------------+---------------+--------------+
466 AT_SETUP([9 big narrow cells])
467 AT_KEYWORDS([render rendering])
468 AT_DATA([input], [1 9
469 @This cell has a lot of text but its minimum width is pretty narrow.
470 @This cell also has a lot of text but its minimum width is pretty narrow.
471 @A third cell with a lot of text but a pretty narrow minimum width.
472 @A fourth cell with a lot of text but a pretty narrow minimum width.
473 @A fifth cell with a lot of text but a pretty narrow minimum width.
474 @A sixth cell with a lot of text but a pretty narrow minimum width.
475 @A seventh cell with a lot of text but a pretty narrow minimum width.
476 @A eighth cell with a lot of text but a pretty narrow minimum width.
477 @A ninth cell with a lot of text but a pretty narrow minimum width.
479 AT_CHECK([render-test input], [0], [dnl
480 +--------+-------+--------+--------+-------+--------+--------+-------+--------+
481 | This| This| A third|A fourth|A fifth| A sixth| A| A| A ninth|
482 |cell has| cell| cell| cell| cell| cell| seventh| eighth| cell|
483 |a lot of| also| with a| with a| with a| with a| cell| cell| with a|
484 |text but| has a| lot of| lot of| lot of| lot of| with a| with a| lot of|
485 | its| lot of|text but|text but| text|text but| lot of| lot of|text but|
486 | minimum| text|a pretty|a pretty| but a|a pretty|text but| text|a pretty|
487 |width is|but its| narrow| narrow| pretty| narrow|a pretty| but a| narrow|
488 | pretty|minimum| minimum| minimum| narrow| minimum| narrow| pretty| minimum|
489 | narrow.| width| width.| width.|minimum| width.| minimum| narrow| width.|
490 | | is| | | width.| | width.|minimum| |
491 | | pretty| | | | | | width.| |
492 | |narrow.| | | | | | | |
493 +--------+-------+--------+--------+-------+--------+--------+-------+--------+
497 AT_SETUP([2 big cells with new-lines])
498 AT_KEYWORDS([render rendering])
499 AT_DATA([input], [1 2
500 @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.
501 @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.
503 AT_CHECK([render-test input], [0], [dnl
504 +----------------------------------------------------------+------------------+
505 | PSPP does not place many restrictions on ordering of| PSPP includes|
506 | commands. The main restriction is that variables must be| special support|
507 | defined before they are otherwise referenced. This| for unknown|
508 | section describes the details of command ordering, but| numeric data|
509 | most users will have no need to refer to them. PSPP| values.|
510 | possesses five internal states, called initial, INPUT| Missing|
511 | PROGRAM, FILE TYPE, transformation, and procedure states.| observations are|
513 | | a special value,|
515 | | ``system‑missing|
517 | |``value'' actually|
523 | | value is unknown.|
524 +----------------------------------------------------------+------------------+
528 AT_SETUP([8x8 with many 2x2 joins])
529 AT_KEYWORDS([render rendering])
530 AT_DATA([input], [WEAVE_8X8_2])
531 AT_CHECK([render-test input], [0],[dnl
558 AT_SETUP([ASCII driver Unicode box characters])
559 AT_KEYWORDS([render rendering])
560 AT_DATA([input], [3 3
567 AT_CHECK([render-test --box=unicode input], [0], [dnl
568 â•â”€â”€â”€â”¬â”€â•®
574 ╰─┴───╯
578 AT_BANNER([output rendering -- horizontal page breaks])
580 AT_SETUP([breaking row of many small cells])
581 AT_KEYWORDS([render rendering])
582 AT_CAPTURE_FILE([input])
583 AT_DATA([input], [1 50
584 m4_for([x], [1], [50], [1], [@x
586 AT_CHECK([render-test input], [0], [dnl
587 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
588 |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|
589 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
591 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
592 |30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49|50|
593 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
595 AT_CHECK([render-test input -o mb0 --min-break=0], [0], [dnl
596 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
597 |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|
598 +-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
600 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
601 |30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49|50|
602 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
606 AT_SETUP([breaking row of many small cells, with headers])
607 AT_KEYWORDS([render rendering])
608 AT_CAPTURE_FILE([input])
609 AT_DATA([input], [1 54 2 2
612 m4_for([x], [1], [50], [1], [@x
617 AT_CHECK([render-test input], [0], [dnl
618 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
619 |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|
620 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
622 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
623 |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|
624 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
626 +--+--+--+--+--+--+--+
627 |ha|hb|48|49|50|hc|hd|
628 +--+--+--+--+--+--+--+
630 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
631 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
632 |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|
633 +--+--+-+-+-+-+-+-+-+-+-+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
635 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
636 |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|
637 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
639 +--+--+--+--+--+--+--+
640 |ha|hb|48|49|50|hc|hd|
641 +--+--+--+--+--+--+--+
645 AT_SETUP([breaking row of many medium-size cells])
646 AT_KEYWORDS([render rendering])
647 AT_CAPTURE_FILE([input])
648 AT_DATA([input], [1 50
649 m4_for([x], [1], [50], [1], [@cell x
651 AT_CHECK([render-test input], [0], [dnl
652 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
653 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|
654 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15|
655 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
657 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
658 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|
659 | 16| 17| 18| 19| 20| 21| 22| 23| 24| 25| 26| 27| 28| 29| 30|
660 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
662 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
663 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|
664 | 31| 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 45|
665 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+
667 +----+----+----+----+----+
668 |cell|cell|cell|cell|cell|
669 | 46| 47| 48| 49| 50|
670 +----+----+----+----+----+
672 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
673 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+---
674 |cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cel
675 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15| 1
676 +----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+---
678 -+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+--
679 l|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|ce
680 6| 17| 18| 19| 20| 21| 22| 23| 24| 25| 26| 27| 28| 29| 30| 31|
681 -+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+--
683 --+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+-
684 ll|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|c
685 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 45| 46| 47|
686 --+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+-
695 AT_SETUP([breaking row of many medium-size cells, with headers])
696 AT_KEYWORDS([render rendering])
697 AT_CAPTURE_FILE([input])
698 AT_DATA([input], [1 52 1 1
700 m4_for([x], [1], [50], [1], [@cell x
704 AT_CHECK([render-test input], [0], [dnl
705 +----+----+----+----+----+----+----+----+----+----+----+----+
706 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
707 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12|
708 +----+----+----+----+----+----+----+----+----+----+----+----+
710 +----+----+----+----+----+----+----+----+----+----+----+----+
711 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
712 | 13| 14| 15| 16| 17| 18| 19| 20| 21| 22| 23| 24|
713 +----+----+----+----+----+----+----+----+----+----+----+----+
715 +----+----+----+----+----+----+----+----+----+----+----+----+
716 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
717 | 25| 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36|
718 +----+----+----+----+----+----+----+----+----+----+----+----+
720 +----+----+----+----+----+----+----+----+----+----+----+----+
721 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
722 | 37| 38| 39| 40| 41| 42| 43| 44| 45| 46| 47| 48|
723 +----+----+----+----+----+----+----+----+----+----+----+----+
726 header1|cell|cell|header2
730 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
731 +----+----+----+----+----+----+----+----+----+----+----+----+--+
732 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|ce|header2
733 | 1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| |
734 +----+----+----+----+----+----+----+----+----+----+----+----+--+
736 +--+----+----+----+----+----+----+----+----+----+----+----+----+
737 header1|ll|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
738 |13| 14| 15| 16| 17| 18| 19| 20| 21| 22| 23| 24| 25|
739 +--+----+----+----+----+----+----+----+----+----+----+----+----+
741 +----+----+----+----+----+----+----+----+----+----+----+----+--+
742 header1|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|ce|header2
743 | 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36| 37| |
744 +----+----+----+----+----+----+----+----+----+----+----+----+--+
746 +--+----+----+----+----+----+----+----+----+----+----+----+----+
747 header1|ll|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|cell|header2
748 |38| 39| 40| 41| 42| 43| 44| 45| 46| 47| 48| 49| 50|
749 +--+----+----+----+----+----+----+----+----+----+----+----+----+
753 AT_SETUP([breaking row of many big narrow cells])
754 AT_KEYWORDS([render rendering])
755 AT_CAPTURE_FILE([input])
756 AT_DATA([input], [1 50
757 m4_for([x], [1], [50], [1], [@This is cell x in a series of 50.
759 AT_CHECK([render-test input], [0], [dnl
760 +------+------+------+------+------+------+------+------+------+------+------+
761 | This| This| This| This| This| This| This| This| This| This| This|
762 | is| is| is| is| is| is| is| is| is| is| is|
763 |cell 1|cell 2|cell 3|cell 4|cell 5|cell 6|cell 7|cell 8|cell 9| cell| cell|
764 | in a| in a| in a| in a| in a| in a| in a| in a| in a| 10 in| 11 in|
765 |series|series|series|series|series|series|series|series|series| a| a|
766 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|series|series|
767 | | | | | | | | | |of 50.|of 50.|
768 +------+------+------+------+------+------+------+------+------+------+------+
770 +------+------+------+------+------+------+------+------+------+------+------+
771 | This| This| This| This| This| This| This| This| This| This| This|
772 | is| is| is| is| is| is| is| is| is| is| is|
773 | cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
774 | 12 in| 13 in| 14 in| 15 in| 16 in| 17 in| 18 in| 19 in| 20 in| 21 in| 22 in|
775 | a| a| a| a| a| a| a| a| a| a| a|
776 |series|series|series|series|series|series|series|series|series|series|series|
777 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
778 +------+------+------+------+------+------+------+------+------+------+------+
780 +------+------+------+------+------+------+------+------+------+------+------+
781 | This| This| This| This| This| This| This| This| This| This| This|
782 | is| is| is| is| is| is| is| is| is| is| is|
783 | cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
784 | 23 in| 24 in| 25 in| 26 in| 27 in| 28 in| 29 in| 30 in| 31 in| 32 in| 33 in|
785 | a| a| a| a| a| a| a| a| a| a| a|
786 |series|series|series|series|series|series|series|series|series|series|series|
787 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
788 +------+------+------+------+------+------+------+------+------+------+------+
790 +------+------+------+------+------+------+------+------+------+------+------+
791 | This| This| This| This| This| This| This| This| This| This| This|
792 | is| is| is| is| is| is| is| is| is| is| is|
793 | cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
794 | 34 in| 35 in| 36 in| 37 in| 38 in| 39 in| 40 in| 41 in| 42 in| 43 in| 44 in|
795 | a| a| a| a| a| a| a| a| a| a| a|
796 |series|series|series|series|series|series|series|series|series|series|series|
797 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
798 +------+------+------+------+------+------+------+------+------+------+------+
800 +------+------+------+------+------+------+
801 | This| This| This| This| This| This|
802 | is| is| is| is| is| is|
803 | cell| cell| cell| cell| cell| cell|
804 | 45 in| 46 in| 47 in| 48 in| 49 in| 50 in|
806 |series|series|series|series|series|series|
807 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
808 +------+------+------+------+------+------+
810 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
811 +------+------+------+------+------+------+------+------+------+------+------+-
812 | This| This| This| This| This| This| This| This| This| This| This|
813 | is| is| is| is| is| is| is| is| is| is| is|
814 |cell 1|cell 2|cell 3|cell 4|cell 5|cell 6|cell 7|cell 8|cell 9| cell| cell|
815 | in a| in a| in a| in a| in a| in a| in a| in a| in a| 10 in| 11 in|
816 |series|series|series|series|series|series|series|series|series| a| a|
817 |of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|series|series|s
818 | | | | | | | | | |of 50.|of 50.|o
819 +------+------+------+------+------+------+------+------+------+------+------+-
821 -----+------+------+------+------+------+------+------+------+------+------+---
822 This| This| This| This| This| This| This| This| This| This| This| T
823 is| is| is| is| is| is| is| is| is| is| is|
824 cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| c
825 12 in| 13 in| 14 in| 15 in| 16 in| 17 in| 18 in| 19 in| 20 in| 21 in| 22 in| 23
826 a| a| a| a| a| a| a| a| a| a| a|
827 eries|series|series|series|series|series|series|series|series|series|series|ser
828 f 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of
829 -----+------+------+------+------+------+------+------+------+------+------+---
831 ---+------+------+------+------+------+------+------+------+------+------+-----
832 his| This| This| This| This| This| This| This| This| This| This| Thi
833 is| is| is| is| is| is| is| is| is| is| is| i
834 ell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cel
835 in| 24 in| 25 in| 26 in| 27 in| 28 in| 29 in| 30 in| 31 in| 32 in| 33 in| 34 i
836 a| a| a| a| a| a| a| a| a| a| a|
837 ies|series|series|series|series|series|series|series|series|series|series|serie
838 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50
839 ---+------+------+------+------+------+------+------+------+------+------+-----
841 -+------+------+------+------+------+------+------+------+------+------+------+
842 s| This| This| This| This| This| This| This| This| This| This| This|
843 s| is| is| is| is| is| is| is| is| is| is| is|
844 l| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell| cell|
845 n| 35 in| 36 in| 37 in| 38 in| 39 in| 40 in| 41 in| 42 in| 43 in| 44 in| 45 in|
846 a| a| a| a| a| a| a| a| a| a| a| a|
847 s|series|series|series|series|series|series|series|series|series|series|series|
848 .|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|of 50.|
849 -+------+------+------+------+------+------+------+------+------+------+------+
851 +------+------+------+------+------+
852 | This| This| This| This| This|
853 | is| is| is| is| is|
854 | cell| cell| cell| cell| cell|
855 | 46 in| 47 in| 48 in| 49 in| 50 in|
857 |series|series|series|series|series|
858 |of 50.|of 50.|of 50.|of 50.|of 50.|
859 +------+------+------+------+------+
863 AT_SETUP([breaking 2 rows of many small cells])
864 AT_KEYWORDS([render rendering])
865 AT_CAPTURE_FILE([input])
866 AT_DATA([input], [2 50
867 m4_for([x], [1], [100], [1], [@x
869 AT_CHECK([render-test input], [0], [dnl
870 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
871 | 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|
872 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
873 |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|
874 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
876 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
877 |27|28|29|30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49| 50|
878 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
879 |77|78|79|80|81|82|83|84|85|86|87|88|89|90|91|92|93|94|95|96|97|98|99|100|
880 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
882 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
883 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
884 | 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|
885 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
886 |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|
887 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
889 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
890 |27|28|29|30|31|32|33|34|35|36|37|38|39|40|41|42|43|44|45|46|47|48|49| 50|
891 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
892 |77|78|79|80|81|82|83|84|85|86|87|88|89|90|91|92|93|94|95|96|97|98|99|100|
893 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+---+
897 AT_SETUP([breaking 3 rows with many joined cells])
898 AT_KEYWORDS([render rendering])
899 AT_CAPTURE_FILE([input])
900 AT_DATA([input], [3 49
901 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
902 A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W], [var
904 m4_for([x], [2], [49], [1], [1*2 @x
907 AT_CHECK([render-test input], [0], [dnl
908 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
909 +-+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
910 |1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15| 16| 17| 18| 19| 20|
911 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
912 | 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 4
913 +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+--
916 +---+---+---+---+----+
917 | 21| 22| 23| 24| 25|
918 +-+-+-+-+-+-+-+-+-+--+
919 45| 46| 47| 48| 49|50|
920 --+---+---+---+---+--+
922 AT_CHECK([render-test -o mb0 --min-break=0 input], [0], [dnl
923 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
924 +-+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
925 |1| 2| 3| 4| 5| 6| 7| 8| 9| 10| 11| 12| 13| 14| 15| 16| 17| 18| 19| 20|
926 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
927 | 26| 27| 28| 29| 30| 31| 32| 33| 34| 35| 36| 37| 38| 39| 40| 41| 42| 43| 44| 4
928 +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+--
931 +---+---+---+---+----+
932 | 21| 22| 23| 24| 25|
933 +-+-+-+-+-+-+-+-+-+--+
934 45| 46| 47| 48| 49|50|
935 --+---+---+---+---+--+
939 AT_SETUP([horz break 6x6, joined rows and columns])
940 AT_KEYWORDS([render rendering])
941 AT_DATA([input], [WEAVE_6X6])
942 AT_DATA([expout], [dnl
985 AT_CHECK([render-test --width=6 input], [0], [expout])
986 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [expout])
989 AT_SETUP([horz break 6x6, joined rows and columns, left header])
990 AT_KEYWORDS([render rendering])
991 AT_DATA([input], [WEAVE_6X6([1 0 0 0])])
992 AT_DATA([expout], [dnl
1021 AT_CHECK([render-test --width=10 input], [0], [expout])
1022 AT_CHECK([render-test -o mb0 --min-break=0 --width=10 input], [0], [expout])
1025 AT_SETUP([horz break 6x6, joined rows and columns, right header])
1026 AT_KEYWORDS([render rendering])
1027 AT_DATA([input], [WEAVE_6X6([0 1 0 0])])
1028 AT_DATA([expout], [dnl
1057 AT_CHECK([render-test --width=10 input], [0], [expout])
1058 AT_CHECK([render-test -o mb0 --min-break=0 --width=10 input], [0], [expout])
1061 AT_SETUP([breaking joined cells too wide for page])
1062 AT_KEYWORDS([render rendering])
1063 AT_DATA([input], [4 6
1064 1*6 @abc def ghi jkl
1077 AT_CHECK([render-test --width=10 input], [0], [dnl
1102 AT_CHECK([render-test -o mb0 --min-break=0 --width=10 input], [0], [dnl
1129 AT_SETUP([breaking joined cells much too wide for page])
1130 AT_KEYWORDS([render rendering])
1131 AT_DATA([input], [4 6
1132 1*6 @abc def ghi jkl
1145 AT_CHECK([render-test --width=6 input], [0], [dnl
1182 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [dnl
1221 AT_SETUP([breaking cell too wide for page, no border])
1222 AT_KEYWORDS([render rendering])
1223 AT_CAPTURE_FILE([input])
1224 AT_DATA([input], [1 1
1225 abcdefghijklmnopqrstuvwxyz
1227 AT_CHECK([render-test --width=6 input], [0], [dnl
1238 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [dnl
1251 AT_SETUP([breaking cell too wide for page, with border])
1252 AT_KEYWORDS([render rendering])
1253 AT_CAPTURE_FILE([input])
1254 AT_DATA([input], [1 1
1255 @abcdefghijklmnopqrstuvwxyz
1257 AT_DATA([expout], [dnl
1278 AT_CHECK([render-test --width=6 input], [0], [expout])
1279 AT_CHECK([render-test -o mb0 --min-break=0 --width=6 input], [0], [expout])
1282 AT_SETUP([horz break 8x8 with many 2x2 joins])
1283 AT_KEYWORDS([render rendering])
1284 AT_DATA([input], [WEAVE_8X8_2])
1285 AT_CHECK([render-test --width=8 input], [0],[dnl
1355 AT_CHECK([render-test -o mb0 --min-break=0 --width=8 input], [0],[dnl
1427 AT_BANNER([output rendering -- problematic procedures])
1429 dnl LIST used to put columns right up next to each other without any
1430 dnl intervening space, so this checks for regression.
1431 AT_SETUP([LIST puts space between columns])
1432 AT_KEYWORDS([render rendering])
1433 AT_DATA([list.sps], [dnl
1434 DATA LIST LIST NOTABLE /x y z (F1.0).
1442 AT_CHECK([pspp list.sps], [0], [dnl
1454 # Long string variables tend to end in lots of spaces. The ASCII
1455 # driver didn't handle this very well: it would essentially produce
1456 # one blank line in a cell for each trailing space. This test
1457 # checks for regression. See bug #38672.
1458 AT_SETUP([ASCII driver renders end of line spaces reasonably])
1459 AT_KEYWORDS([render rendering])
1460 AT_DATA([input], [dnl
1472 AT_CHECK([render-test --width=15 --length=15 input], [0], [dnl
1483 # There was a bug that, when multiple cells spanned a single column
1484 # (or row), only the dimensions of the cell nearest the bottom of the
1485 # table were actually considered. This checks for regression. (This
1486 # problem was most easily observed with SYSFILE INFO, which uses lots
1487 # of spanned cells).
1489 # Without the fix, the output looks like this:
1496 AT_SETUP([multiple spanned cells all contribute to dimensions])
1497 AT_KEYWORDS([render rendering])
1498 AT_DATA([input], [dnl
1500 1*2 @A long text string.
1503 AT_CHECK([render-test --width=30 --length=15 input], [0], [dnl
1504 +--------------------+
1505 | A long text string.|
1506 +--------------------+
1508 +--------------------+