Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-8319

Velocity template example from wiki fails when copy-pasted

    XMLWordPrintableJSON

Details

    • Task
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.14.1
    • 2.15.0
    • documentation
    • None
    • Unknown

    Description

      I was following the velocity template example on the wiki and had some confusion over why it was failing. I was even more confused when the same test worked in the camel-velocity component project.

      What I did was cut-and-paste the template from the wiki page into letter.vm, and also cut-and-paste the unit test code into a JUnit test.

      Finally I noticed that the velocity template, when transcluded in the wiki page, has extra spaces in the empty lines that make it different than the one expected by the test. Perhaps you can figure out a way to prevent the extra space from being added to the template when shown on the wiki, or modify the template so that it doesn't get affected by that whitespace. Just want to avoid someone else getting confused like I did.

      Attachments

        Activity

          People

            davsclaus Claus Ibsen
            pimlottc Chris Pimlott
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: