Uploaded image for project: 'Hippo CMS'
  1. Hippo CMS
  2. CMS-10465

IconUtilTest failing on Windows machine

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.1.0
    • Component/s: None
    • Labels:
      None
    • Similar issues:

      Description

      Running the CMS unit tests on my Windows machine fails because of hardcoded line endings in org.hippoecm.frontend.skin.IconUtilTest#svg_as_string_from_resource_reference.

      The failure shows:

      java.lang.AssertionError: 
      Expected: a string ending with "</svg>\n"
           got: "<svg version=\"1.0\" xmlns=\"http://www.w3.org/2000/svg\"\r\n width=\"178.000000pt\" height=\"145.000000pt\" viewBox=\"0 0 178.000000 145.000000\"\r\n preserveAspectRatio=\"xMidYMid meet\">\r\n<metadata>\r\nCreated by potrace 1.10, written by Peter Selinger 2001-2011\r\n</metadata>\r\n<g transform=\"translate(0.000000,145.000000) scale(0.100000,-0.100000)\"\r\nfill=\"#000000\" stroke=\"none\">\r\n<path d=\"M0  [SKIPPED CHARACTERS]  2 1 -13 -2 -25 -8z\"/>\r\n</g>\r\n</svg>\r\n"
      

      If the usage of \n is replaced by System.getProperty("line.separator") the test does not fail.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              jhoffman Jeroen Hoffman
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: