source: trunk/source/tests/ansi-tests/print-lines.lsp @ 8991

Last change on this file since 8991 was 8991, checked in by gz, 12 years ago

Check in the gcl ansi test suite (original, in preparation for making local changes)

File size: 841 bytes
Line 
1;-*- Mode:     Lisp -*-
2;;;; Author:   Paul Dietz
3;;;; Created:  Tue Jul 27 09:32:46 2004
4;;;; Contains: Tests involving PRINT-LINES
5
6(in-package :cl-test)
7
8(compile-and-load "printer-aux.lsp")
9
10(deftest print-lines.1
11  *print-lines*
12  nil)
13
14(deftest print-lines.2
15  (with-standard-io-syntax
16   (let ((*print-lines* 1)
17         (*print-readably* nil)
18         (*print-miser-width* nil)
19         (*print-pprint-dispatch* (copy-pprint-dispatch)))
20     (set-pprint-dispatch '(cons (eql 1) t) 'pprint-fill)
21     (apply
22      #'values
23      (loop for i from 1 to 10
24            collect
25            (let ((*print-right-margin* i))
26              (subseq
27               (with-output-to-string
28                 (*standard-output*)
29                 (terpri)
30                 (pprint '(1 2 3 4 5 6 7 8 9)))
31               2))))))
32  "(1 ..)"
33  "(1 ..)"
34  "(1 ..)"
35  "(1 ..)"
36  "(1 ..)"
37  "(1 ..)"
38  "(1 ..)"
39  "(1 2 ..)"
40  "(1 2 ..)"
41  "(1 2 3 ..)")
42
Note: See TracBrowser for help on using the repository browser.