Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-1463

println prepends erroneous "." to result of Class#getSimpleName()

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Won't Fix
    • 1.0-JSR-6
    • 1.0-RC-1
    • None
    • None
    • Groovy Version: 1.0-JSR-06 JVM: 1.5.0_06-b05

    Description

      Result of this test:

      class DbServiceTest extends GroovyTestCase {
      void testSomething()

      { def name = GroovyTestCase.class.simpleName assertEquals(GroovyTestCase.class.simpleName, name) assertTrue(name.length() == "GroovyTestCase".length()) println name println name }

      }

      is:

      .GroovyTestCase
      GroovyTestCase

      Time: 0.016

      OK (1 test)

      Where is the period coming from?

      Attachments

        1. PrinlnTest.groovy
          0.3 kB
          Jeff Wild

        Activity

          jawild59 Jeff Wild added a comment -

          Looks like it's output from a testXXX method. An empty testXXX() also outputs a "."

          jawild59 Jeff Wild added a comment - Looks like it's output from a testXXX method. An empty testXXX() also outputs a "."

          The . is output from JUnit and is expected which is why Guillaume closed this issue and marked it `won't fix' – there is nothing to fix!

          russel Dr. Russel Winder added a comment - The . is output from JUnit and is expected which is why Guillaume closed this issue and marked it `won't fix' – there is nothing to fix!

          People

            guillaume Guillaume Sauthier
            jawild59 Jeff Wild
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: