File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ import sharedNeo4j from '../internal/shared-neo4j';
27
27
import _ from 'lodash' ;
28
28
import { ServerVersion , VERSION_3_1_0 } from '../../src/v1/internal/server-version' ;
29
29
import { isString } from '../../src/v1/internal/util' ;
30
+ import testUtils from '../internal/test-utils' ;
30
31
31
32
describe ( 'session' , ( ) => {
32
33
@@ -1176,14 +1177,22 @@ describe('session', () => {
1176
1177
}
1177
1178
1178
1179
function testConnectionTimeout ( encrypted , done ) {
1180
+ if ( testUtils . isClient ( ) && encrypted ) {
1181
+ // skip encrypted test in browser because it runs all tests in a HTTP page
1182
+ done ( ) ;
1183
+ return ;
1184
+ }
1185
+
1179
1186
const boltUri = 'bolt://10.0.0.0' ; // use non-routable IP address which never responds
1180
1187
const config = { encrypted : encrypted , connectionTimeout : 1000 } ;
1181
1188
1182
1189
const localDriver = neo4j . driver ( boltUri , sharedNeo4j . authToken , config ) ;
1183
1190
const session = localDriver . session ( ) ;
1184
1191
session . run ( 'RETURN 1' ) . then ( ( ) => {
1192
+ localDriver . close ( ) ;
1185
1193
done . fail ( 'Query did not fail' ) ;
1186
1194
} ) . catch ( error => {
1195
+ localDriver . close ( ) ;
1187
1196
expect ( error . code ) . toEqual ( neo4j . error . SERVICE_UNAVAILABLE ) ;
1188
1197
1189
1198
// in some environments non-routable address results in immediate 'connection refused' error and connect
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ describe('temporal-types', () => {
46
46
47
47
beforeAll ( done => {
48
48
originalTimeout = jasmine . DEFAULT_TIMEOUT_INTERVAL ;
49
- jasmine . DEFAULT_TIMEOUT_INTERVAL = 30000 ;
49
+ jasmine . DEFAULT_TIMEOUT_INTERVAL = 60000 ;
50
50
51
51
driver = neo4j . driver ( 'bolt://localhost' , sharedNeo4j . authToken ) ;
52
52
driverWithNativeNumbers = neo4j . driver ( 'bolt://localhost' , sharedNeo4j . authToken , { disableLosslessIntegers : true } ) ;
You can’t perform that action at this time.
0 commit comments