JUnit assertEquals Changes String
问题 I have a JUnit test that is as follows: @Test public void testToDatabaseString() { DateConvertor convertor = new DateConvertor(); Date date = convertor.convert("20/07/1984:00:00:00:00"); String convertedDate = convertor.toDatabaseString(date); assertEquals("to_date('20/07/1984:00:00:00:00', 'DD/MM/YYYY HH24:MI:SS')",convertedDate); } The test fails stating: org.junit.ComparisonFailure: expected:<to_date('20/07/1984[00:]00:00:00', 'DD/MM/YY...> but was:<to_date('20/07/1984[ ]00:00:00', 'DD/MM