Skip to content

Commit 2c1041e

Browse files
author
Zhen
committed
Merge branch '1.0' into 1.1
2 parents 80c5f1a + a28194f commit 2c1041e

File tree

5 files changed

+7
-9
lines changed

5 files changed

+7
-9
lines changed

driver/src/main/java/org/neo4j/driver/internal/connector/socket/SocketConnection.java

+1
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ public SocketConnection( String host, int port, Config config )
6767
public void init( String clientName, Map<String,Value> authToken )
6868
{
6969
queueMessage( new InitMessage( clientName, authToken ), StreamCollector.NO_OP );
70+
sync();
7071
}
7172

7273
@Override

driver/src/test/java/org/neo4j/driver/v1/integration/CredentialsIT.java

+1-4
Original file line numberDiff line numberDiff line change
@@ -74,15 +74,12 @@ public void shouldGetHelpfulErrorOnInvalidCredentials() throws Throwable
7474
String password = "secret";
7575
enableAuth( password );
7676

77-
Driver driver = GraphDatabase.driver( neo4j.address(), basic("thisisnotthepassword", password ) );
78-
Session session = driver.session();
79-
8077
// Expect
8178
exception.expect( ClientException.class );
8279
exception.expectMessage( "The client is unauthorized due to authentication failure." );
8380

8481
// When
85-
session.run( "RETURN 1" ).single().get(0);
82+
GraphDatabase.driver( neo4j.address(), basic("thisisnotthepassword", password ) ).session();
8683
}
8784

8885
private void enableAuth( String password ) throws Exception

driver/src/test/java/org/neo4j/driver/v1/integration/ErrorIT.java

+1-3
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,7 @@ public void shouldThrowHelpfulSyntaxError() throws Throwable
4848
{
4949
// Expect
5050
exception.expect( ClientException.class );
51-
exception.expectMessage( "Invalid input 'i': expected <init> (line 1, column 1 (offset: 0))\n" +
52-
"\"invalid statement\"\n" +
53-
" ^" );
51+
exception.expectMessage( "Invalid input 'i'" );
5452

5553
// When
5654
StatementResult result = session.run( "invalid statement" );

driver/src/test/java/org/neo4j/driver/v1/tck/DriverComplianceIT.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@
3232
* The base class to run all cucumber tests
3333
*/
3434
@RunWith( DriverCucumberAdapter.class )
35-
@CucumberOptions( features = {"target/resources/features"}, strict=true, tags={"~@db", "~@fixed_session_pool"}, format = {"pretty"})
35+
@CucumberOptions( features = {"target/resources/features"}, strict=true, tags={"~@db", "~@fixed_session_pool"},
36+
format = {"default_summary"})
3637
public class DriverComplianceIT
3738
{
3839
@Rule

driver/src/test/java/org/neo4j/driver/v1/tck/Environment.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public void resetValues()
6363
statementRunner = null;
6464
stringRunner = null;
6565
runners = new ArrayList<>();
66-
mappedTypes = new HashMap<>( );
66+
mappedTypes = new HashMap<>();
6767
driver = neo4j.driver();
6868
}
6969

@@ -79,6 +79,7 @@ public void closeRunners()
7979
@Before("@reset_database")
8080
public void emptyDatabase()
8181
{
82+
Driver driver = neo4j.driver();
8283
try ( Session session = driver.session())
8384
{
8485
session.run( "MATCH (n) DETACH DELETE n" );

0 commit comments

Comments
 (0)