Skip to content
This repository was archived by the owner on Jul 6, 2023. It is now read-only.
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
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ ext {

argparse4jVersion = '0.7.0'
junitVersion = '4.12'
neo4jJavaVersion = '1.2.1'
neo4jJavaVersion = '1.4.0'
findbugsVersion = '3.0.0'
jansiVersion = '1.13'
jlineVersion = '2.14.2'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;
import static org.mockito.Matchers.any;
import static org.mockito.Matchers.anyString;
import static org.mockito.Mockito.anyObject;
import static org.mockito.Mockito.doReturn;
import static org.mockito.Mockito.doThrow;
Expand All @@ -56,7 +57,7 @@ public class BoltStateHandlerTest {

@Before
public void setup() {
when(mockDriver.session(any(), any())).thenReturn(new FakeSession());
when(mockDriver.session(any(), anyString())).thenReturn(new FakeSession());
doReturn(System.out).when(logger).getOutputStream();
}

Expand Down Expand Up @@ -303,7 +304,7 @@ public void triesAgainOnSessionExpired() throws Exception {
BoltResult boltResult = boltStateHandler.runCypher("RETURN 999",
new HashMap<>()).get();

verify(driverMock, times(2)).session(any(), any());
verify(driverMock, times(2)).session(any(), anyString());
verify(sessionMock, times(2)).run(any(Statement.class));

assertEquals("999", boltResult.getRecords().get(0).get(0).toString());
Expand Down Expand Up @@ -396,7 +397,7 @@ private Driver stubVersionInAnOpenSession(StatementResult versionMock, Session s

when(sessionMock.isOpen()).thenReturn(true);
when(sessionMock.run("RETURN 1")).thenReturn(versionMock);
when(driverMock.session(any(), any())).thenReturn(sessionMock);
when(driverMock.session(any(), anyString())).thenReturn(sessionMock);

return driverMock;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,16 @@ public Session session( AccessMode mode, String bookmark )
return new FakeSession();
}

@Override
public Session session(Iterable<String> bookmarks) {
return new FakeSession();
}

@Override
public Session session(AccessMode mode, Iterable<String> bookmarks) {
return new FakeSession();
}

@Override
public void close() throws Neo4jException {
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,11 @@ public boolean asBoolean() {
throw new Uncoercible(getClass().getSimpleName(), "Bool");
}

@Override
public byte[] asByteArray() {
throw new Uncoercible(getClass().getSimpleName(), "Byte[]");
}

@Override
public String asString() {
throw new Uncoercible(getClass().getSimpleName(), "String");
Expand Down