Skip to content

Turn off UTC tests until server implementation is available #1262

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@
import org.neo4j.driver.Record;
import org.neo4j.driver.Result;
import org.neo4j.driver.Value;
import org.neo4j.driver.internal.util.DisabledOnNeo4jWith;
import org.neo4j.driver.internal.util.EnabledOnNeo4jWith;
import org.neo4j.driver.internal.util.Neo4jFeature;
import org.neo4j.driver.types.IsoDuration;
import org.neo4j.driver.util.ParallelizableIT;
import org.neo4j.driver.util.SessionExtension;
Expand Down Expand Up @@ -173,12 +175,14 @@ void shouldSendAndReceiveListsWithRandomLocalDateTimes() {
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendDateTimeWithZoneOffset() {
ZoneOffset offset = ZoneOffset.ofHoursMinutes(-4, -15);
testSendValue(ZonedDateTime.of(1845, 3, 25, 19, 15, 45, 22, offset), Value::asZonedDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldReceiveDateTimeWithZoneOffset() {
ZoneOffset offset = ZoneOffset.ofHoursMinutes(3, 30);
testReceiveValue(
Expand All @@ -188,27 +192,32 @@ void shouldReceiveDateTimeWithZoneOffset() {
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveDateTimeWithZoneOffset() {
ZoneOffset offset = ZoneOffset.ofHoursMinutes(-7, -15);
testSendAndReceiveValue(ZonedDateTime.of(2017, 3, 9, 11, 12, 13, 14, offset), Value::asZonedDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveRandomDateTimeWithZoneOffset() {
testSendAndReceiveRandomValues(TemporalUtil::randomZonedDateTimeWithOffset, Value::asZonedDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveListsWithRandomDateTimeWithZoneOffsets() {
testSendAndReceiveRandomLists(TemporalUtil::randomZonedDateTimeWithOffset);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendDateTimeRepresentedWithOffsetDateTime() {
testSendValue(OffsetDateTime.of(1851, 9, 29, 1, 29, 42, 987, ZoneOffset.ofHours(-8)), Value::asOffsetDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldReceiveDateTimeRepresentedWithOffsetDateTime() {
testReceiveValue(
"RETURN datetime({year:2121, month:1, day:1, hour:2, minute:2, second:2, timezone:'-07:20'})",
Expand All @@ -217,29 +226,34 @@ void shouldReceiveDateTimeRepresentedWithOffsetDateTime() {
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveDateTimeRepresentedWithOffsetDateTime() {
testSendAndReceiveValue(
OffsetDateTime.of(1998, 12, 12, 23, 54, 14, 123, ZoneOffset.ofHoursMinutes(1, 15)),
Value::asOffsetDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveRandomDateTimeRepresentedWithOffsetDateTime() {
testSendAndReceiveRandomValues(TemporalUtil::randomOffsetDateTime, Value::asOffsetDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveListsWithRandomDateTimeRepresentedWithOffsetDateTimes() {
testSendAndReceiveRandomLists(TemporalUtil::randomOffsetDateTime, value -> value.asList(ofOffsetDateTime()));
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendDateTimeWithZoneId() {
ZoneId zoneId = ZoneId.of("Europe/Stockholm");
testSendValue(ZonedDateTime.of(2049, 9, 11, 19, 10, 40, 20, zoneId), Value::asZonedDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldReceiveDateTimeWithZoneId() {
ZoneId zoneId = ZoneId.of("Europe/London");
testReceiveValue(
Expand All @@ -249,17 +263,20 @@ void shouldReceiveDateTimeWithZoneId() {
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveDateTimeWithZoneId() {
ZoneId zoneId = ZoneId.of("Europe/Stockholm");
testSendAndReceiveValue(ZonedDateTime.of(2099, 12, 29, 12, 59, 59, 59, zoneId), Value::asZonedDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveRandomDateTimeWithZoneId() {
testSendAndReceiveRandomValues(TemporalUtil::randomZonedDateTimeWithZoneId, Value::asZonedDateTime);
}

@Test
@DisabledOnNeo4jWith(Neo4jFeature.BOLT_V5)
void shouldSendAndReceiveListsWithRandomDateTimeWithZoneIds() {
testSendAndReceiveRandomLists(TemporalUtil::randomZonedDateTimeWithZoneId);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import static org.junit.jupiter.api.Assertions.assertTimeoutPreemptively;
import static org.junit.jupiter.api.Assertions.fail;
import static org.neo4j.driver.internal.util.Neo4jFeature.BOLT_V3;
import static org.neo4j.driver.internal.util.Neo4jFeature.BOLT_V5;
import static org.neo4j.driver.util.TestUtil.TX_TIMEOUT_TEST_TIMEOUT;
import static org.neo4j.driver.util.TestUtil.await;

Expand All @@ -46,6 +47,7 @@
import org.neo4j.driver.async.ResultCursor;
import org.neo4j.driver.exceptions.ClientException;
import org.neo4j.driver.exceptions.TransientException;
import org.neo4j.driver.internal.util.DisabledOnNeo4jWith;
import org.neo4j.driver.internal.util.EnabledOnNeo4jWith;
import org.neo4j.driver.util.DriverExtension;
import org.neo4j.driver.util.ParallelizableIT;
Expand Down Expand Up @@ -83,6 +85,7 @@ void shouldSetTransactionMetadata() {
}

@Test
@DisabledOnNeo4jWith(BOLT_V5)
void shouldSetTransactionMetadataAsync() {
Map<String, Object> metadata = new HashMap<>();
metadata.put("hello", "world");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ public enum Neo4jFeature {
SPATIAL_TYPES(new Version(3, 4, 0)),
TEMPORAL_TYPES(new Version(3, 4, 0)),
BOLT_V3(new Version(3, 5, 0)),
BOLT_V4(new Version(4, 0, 0));
BOLT_V4(new Version(4, 0, 0)),
BOLT_V5(new Version(5, 0, 0));

private final Version availableFromVersion;

Expand Down