From 677f87ae0d3cf59b9efe4bb7966c5df257ff8323 Mon Sep 17 00:00:00 2001 From: John Benediktsson Date: Wed, 27 Mar 2013 19:05:20 -0700 Subject: [PATCH] pdf.wrap: adding some tests. --- extra/pdf/wrap/wrap-tests.factor | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 extra/pdf/wrap/wrap-tests.factor diff --git a/extra/pdf/wrap/wrap-tests.factor b/extra/pdf/wrap/wrap-tests.factor new file mode 100644 index 0000000000..3343e04df9 --- /dev/null +++ b/extra/pdf/wrap/wrap-tests.factor @@ -0,0 +1,14 @@ +USING: fonts tools.test ; +IN: pdf.wrap + +{ "hello, " "extra spaces" } [ + "hello, extra spaces" word-split1 +] unit-test + +{ { "hello, " "world " "how " "are " "you?" } } [ + "hello, world how are you?" word-split +] unit-test + +{ { "hello, world " "how are you?" } } [ + "hello, world how are you?" monospace-font 100 visual-wrap +] unit-test