File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
driver/src/test/java/org/neo4j/driver/v1/integration Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change 28
28
import org .neo4j .driver .v1 .Session ;
29
29
import org .neo4j .driver .v1 .StatementResult ;
30
30
import org .neo4j .driver .v1 .exceptions .ClientException ;
31
+ import org .neo4j .driver .v1 .exceptions .Neo4jException ;
31
32
import org .neo4j .driver .v1 .util .TestNeo4j ;
32
33
33
34
import static org .hamcrest .CoreMatchers .equalTo ;
@@ -112,15 +113,17 @@ public void shouldKillLongRunningStatement() throws Throwable
112
113
113
114
fail ("Should have got an exception about statement get killed." );
114
115
}
115
- catch ( ClientException e )
116
+ catch ( Neo4jException e )
116
117
{
117
118
endTime = System .currentTimeMillis ();
118
- assertThat ( e .code (), equalTo ("Neo.ClientError.Procedure.ProcedureCallFailed" ) );
119
-
120
119
assertTrue ( startTime > 0 );
121
120
assertTrue ( endTime - startTime > killTimeout * 1000 ); // get killed by session.kill
122
121
assertTrue ( endTime - startTime < executionTimeout * 1000 / 2 ); // finished before execution finished
123
122
}
123
+ catch ( Exception e )
124
+ {
125
+ fail ( "Should be a Neo4jException" );
126
+ }
124
127
}
125
128
126
129
@ Test
You can’t perform that action at this time.
0 commit comments