Skip to content

Commit

Permalink
Fixed test dependency on GMT+2 timezone
Browse files Browse the repository at this point in the history
  • Loading branch information
davidtinker committed Aug 1, 2013
1 parent 017adb1 commit 12b8b01
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/test/groovy/io/qdb/server/DateTimeParserSpec.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,12 @@ class DateTimeParserSpec extends Specification {
}

def "Format timestamp works"() {
Date d = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ").parse("2013-06-16T21:04:32.123+0200")
def df = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ")
Date d = df.parse("2013-06-16T21:04:32.123+0200")
String s = DateTimeParser.INSTANCE.formatTimestamp(d)
Date d2 = df.parse(s)

expect:
s == "2013-06-16T21:04:32.123+0200"
d == d2
}
}

0 comments on commit 12b8b01

Please sign in to comment.