We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 1cd8451 + adce081 commit 9929475Copy full SHA for 9929475
test/v1/tck/steps/erroreportingsteps.js
@@ -65,16 +65,15 @@ module.exports = function () {
65
this.When(/^I set up a driver to an incorrect port$/, function (callback) {
66
var self = this;
67
var driver = neo4j.driver("bolt://localhost:7777", neo4j.auth.basic(sharedNeo4j.username, sharedNeo4j.password));
68
- driver.onSuccess = function () {
69
- driver.close();
70
- };
71
- driver.onError = function (error) {
72
73
- self.error = error;
74
- callback();
75
76
- driver.session().beginTransaction();
77
- setTimeout(callback, 1000);
+ var session = driver.session();
+ session.run('RETURN 1')
+ .catch(error => {
+ self.error = error;
+ })
+ .then(() => {
+ driver.close();
+ callback();
+ });
78
});
79
80
this.When(/^I set up a driver with wrong scheme$/, function (callback) {
0 commit comments