Search in sources :

Example 11 with OffsetTime

use of java.time.OffsetTime in project jdk8u_jdk by JetBrains.

the class TCKOffsetTime method test_isBefore_null.

@Test(expectedExceptions = NullPointerException.class)
public void test_isBefore_null() {
    OffsetTime a = OffsetTime.of(11, 30, 59, 0, OFFSET_PONE);
    a.isBefore(null);
}
Also used : OffsetTime(java.time.OffsetTime) Test(org.testng.annotations.Test)

Example 12 with OffsetTime

use of java.time.OffsetTime in project jdk8u_jdk by JetBrains.

the class TCKOffsetTime method test_compareTo_null.

@Test(expectedExceptions = NullPointerException.class)
public void test_compareTo_null() {
    OffsetTime a = OffsetTime.of(11, 30, 59, 0, OFFSET_PONE);
    a.compareTo(null);
}
Also used : OffsetTime(java.time.OffsetTime) Test(org.testng.annotations.Test)

Example 13 with OffsetTime

use of java.time.OffsetTime in project jdk8u_jdk by JetBrains.

the class TCKOffsetTime method test_withMinute_normal.

//-----------------------------------------------------------------------
// withMinute()
//-----------------------------------------------------------------------
@Test
public void test_withMinute_normal() {
    OffsetTime base = OffsetTime.of(11, 30, 59, 0, OFFSET_PONE);
    OffsetTime test = base.withMinute(15);
    assertEquals(test, OffsetTime.of(11, 15, 59, 0, OFFSET_PONE));
}
Also used : OffsetTime(java.time.OffsetTime) Test(org.testng.annotations.Test)

Example 14 with OffsetTime

use of java.time.OffsetTime in project jdk8u_jdk by JetBrains.

the class TCKOffsetTime method test_plusSeconds_zero.

@Test
public void test_plusSeconds_zero() {
    OffsetTime base = OffsetTime.of(11, 30, 59, 0, OFFSET_PONE);
    OffsetTime test = base.plusSeconds(0);
    assertEquals(test, base);
}
Also used : OffsetTime(java.time.OffsetTime) Test(org.testng.annotations.Test)

Example 15 with OffsetTime

use of java.time.OffsetTime in project jdk8u_jdk by JetBrains.

the class TCKOffsetTime method test_withOffsetSameInstant_noChange.

@Test
public void test_withOffsetSameInstant_noChange() {
    OffsetTime base = OffsetTime.of(11, 30, 59, 0, OFFSET_PONE);
    OffsetTime test = base.withOffsetSameInstant(OFFSET_PONE);
    assertEquals(test, base);
}
Also used : OffsetTime(java.time.OffsetTime) Test(org.testng.annotations.Test)

Aggregations

OffsetTime (java.time.OffsetTime)95 Test (org.testng.annotations.Test)86 ZonedDateTime (java.time.ZonedDateTime)8 Instant (java.time.Instant)7 LocalTime (java.time.LocalTime)7 Time (java.sql.Time)6 OffsetDateTime (java.time.OffsetDateTime)6 LocalDate (java.time.LocalDate)5 LocalDateTime (java.time.LocalDateTime)5 Date (java.sql.Date)3 ResultSet (java.sql.ResultSet)3 Clock (java.time.Clock)3 PostgresUtils.toPGArrayString (org.jooq.util.postgres.PostgresUtils.toPGArrayString)3 BigDecimal (java.math.BigDecimal)2 PreparedStatement (java.sql.PreparedStatement)2 Timestamp (java.sql.Timestamp)2 DateTimeFormatter (java.time.format.DateTimeFormatter)2 Temporal (java.time.temporal.Temporal)2 TemporalAdjuster (java.time.temporal.TemporalAdjuster)2 UUID (java.util.UUID)2