diff --git a/collects/tests/mzscheme/list.ss b/collects/tests/mzscheme/list.ss index 0aea0bd345..f6519acc96 100644 --- a/collects/tests/mzscheme/list.ss +++ b/collects/tests/mzscheme/list.ss @@ -113,7 +113,18 @@ (for-each (lambda (l) (test '((0 2) (0 3) (1 1)) sort* l)) '(((1 1) (0 2) (0 3)) ((0 2) (1 1) (0 3)) - ((0 2) (0 3) (1 1))))) + ((0 2) (0 3) (1 1)))) + ;; exhaustive tests for 2 and 3 item lists + (for-each (lambda (l) (test '((1 x) (2 y)) sort* l)) + '(((1 x) (2 y)) + ((2 y) (1 x)))) + (for-each (lambda (l) (test '((1 x) (2 y) (3 z)) sort* l)) + '(((1 x) (2 y) (3 z)) + ((2 y) (1 x) (3 z)) + ((2 y) (3 z) (1 x)) + ((3 z) (2 y) (1 x)) + ((3 z) (1 x) (2 y)) + ((1 x) (3 z) (2 y))))) ;; test #:key and #:cache-keys? (let () (define l '((0) (9) (1) (8) (2) (7) (3) (6) (4) (5)))