Uploaded image for project: 'Unitils'
  1. UNI-221

Why assertReflectionEquals not compare Timestamp?

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.1
    • Fix Version/s: 3.3
    • Component/s: reflectionassert
    • Labels:
      None
    • Environment:
      CentOS 5.4 + Tomcat6 + Spring 3 + iBatis + Mysql5

      Description

      I have a question assertReflectionEquals.

      I add at pom.xml below code.

      <dependency>
          <groupId>org.unitils</groupId>
          <artifactId>unitils-core</artifactId>
          <version>3.1</version>
      </dependency>


      Why assertReflectionEquals not compare Timestamp?

      I dont know why below test is success?

      @Test
      public void test()
      {
      Timestamp expected = new Timestamp(System.currentTimeMillis());
      Timestamp actual = new Timestamp(expected.getTime() + 60 * 1000);

      assertReflectionEquals(expected, actual);
      assertNotSame(expected, actual);
      }

        Attachments

          Activity

            People

            • Assignee:
              jeroen@hypernation.be Jeroen H.
              Reporter:
              neomi2428 jace park
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: