From 8cab89a44c4e1fa27d80424618679bf995dc5bad Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 11 Jul 2015 15:31:39 -0400 Subject: [PATCH] Test: Added low-level hyphenation test --- test/text.t.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/test/text.t.cpp b/test/text.t.cpp index e4013f86b..4ea0f780c 100644 --- a/test/text.t.cpp +++ b/test/text.t.cpp @@ -37,7 +37,7 @@ Context context; //////////////////////////////////////////////////////////////////////////////// int main (int argc, char** argv) { - UnitTest t (205); + UnitTest t (206); // Ensure environment has no influence. unsetenv ("TASKDATA"); @@ -103,6 +103,12 @@ int main (int argc, char** argv) t.notok (extractLine (line, text, 10, true, offset), "extractLine 10 '' -> ''"); + text = "AAAAAAAAAABBBBBBBBBB"; + offset = 0; + extractLine (line, text, 10, true, offset); + t.is (line, "AAAAAAAAA-", "extractLine hyphenated unbreakable line"); + t.diag (line); + // void split (std::vector& results, const std::string& input, const char delimiter) std::vector items; std::string unsplit = "";