Uploaded image for project: 'Arquillian'
  1. Arquillian
  2. ARQ-90

Examples and docs use JUnit 3's Assert

XMLWordPrintable

    • Documentation (Ref Guide, User Guide, etc.)

      JUnit 4.6 contains two Assert classes. The first one junit.framework.Assert is used by Arquillian however this one is there only for a backward compatibility with JUnit 3. The other one, org.junit.Assert, is recommended.

      The issue with that is that in docs, the code samples do not contain imports. Therefore, if a user copies the code, code completion will suggest importing the second Assert (org.junit.Assert), in which the assertEquals(double, double) method is deprecated and the test will fail.

      I suggest to modify the examples to:
      a) use org.junit.Assert
      b) use assertEquals(double, double, double) method
      c) propagate this change to docs

            pmuiratbleepbleep Pete Muir (Inactive)
            rhn-engineering-jharting Jozef Hartinger
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: