Skip to content

Commit 1c58a0a

Browse files
committed
Fix integration test
1 parent 49b5070 commit 1c58a0a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/test/java/org/zalando/typemapper/postgres/PgSerializerToDatabaseTestIT.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
@RunWith(Parameterized.class)
4343
public class PgSerializerToDatabaseTestIT extends AbstractTest {
4444

45+
private static final DateTimeFormatter TIMESTAMP_FORMATTER = DateTimeFormatter.ofPattern("yyyy-MM-dd hh:mm:ssx");
4546
private final Object objectToSerialize;
4647
private final String expectedString;
4748
private final int expectedSQLType;
@@ -198,10 +199,12 @@ public static Collection<Object[]> generateData() throws SQLException {
198199
/* 20 */
199200
{new Date(1354338366000L), OffsetDateTime.parse("2012-12-01T06:06:06+01:00")
200201
.atZoneSameInstant(ZoneId.systemDefault())
201-
.format(DateTimeFormatter.ofPattern("yyyy-MM-dd hh:mm:ssx")), Types.TIMESTAMP},
202+
.format(TIMESTAMP_FORMATTER), Types.TIMESTAMP},
202203

203204
/* 21 */
204-
{new Date(1349064366000L), "2012-10-01 06:06:06+02", Types.TIMESTAMP},
205+
{new Date(1349064366000L), OffsetDateTime.parse("2012-10-01T06:06:06+02:00")
206+
.atZoneSameInstant(ZoneId.systemDefault())
207+
.format(TIMESTAMP_FORMATTER), Types.TIMESTAMP},
205208

206209
/* 22 */
207210
{PgTypeHelper.asPGobject(

0 commit comments

Comments
 (0)