Skip to content

Commit

Permalink
fix(tests): Fixed tests due to newer ts and node versions
Browse files Browse the repository at this point in the history
  • Loading branch information
Bastianowicz committed Nov 14, 2021
1 parent 3dd5812 commit 3a39a45
Show file tree
Hide file tree
Showing 4 changed files with 5,299 additions and 5,193 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"typings": "dist/typings/index.d.ts",
"sideEffects": false,
"engines": {
"node": ">=6"
"node": ">=8"
},
"keywords": [
"cypher",
Expand Down
9 changes: 6 additions & 3 deletions src/builder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import { Clause } from './clause';
import { RemoveProperties } from './clauses/remove';
import { Union } from './clauses/union';
import { ReturnOptions } from './clauses/return';
import {NestedKeyOf, StringKeyOf, TypedDictionary, ValueOf} from './types';
import { NestedKeyOf, StringKeyOf, TypedDictionary, ValueOf } from './types';
import { Query } from './query';
import { Selector } from './selector';
import { ReturnObject, Selectable } from './clauses/returnObject';
Expand All @@ -29,7 +29,6 @@ export interface WrapperClause {
new(clause: Set): Clause;
}


/**
* @internal
*/
Expand Down Expand Up @@ -551,7 +550,11 @@ export abstract class Builder
* @returns {Q}
*/
orderBy(
fields: StringKeyOf<G> | NestedKeyOf<G> | (StringKeyOf<G> | NestedKeyOf<G> | OrderConstraint)[] | OrderConstraints,
fields:
StringKeyOf<G>
| NestedKeyOf<G>
| (StringKeyOf<G> | NestedKeyOf<G> | OrderConstraint)[]
| OrderConstraints,
dir?: Direction) {
return this.continueChainClause(new OrderBy(fields, dir));
}
Expand Down
2 changes: 2 additions & 0 deletions tests/connection.mock.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ export function mockConnection(
url = defaultUrl,
credentials = defaultCredentials,
) {
// @ts-ignore
const session: Session = {
close: spy(),
run: stub().returns(Promise.resolve(true)),
Expand All @@ -17,6 +18,7 @@ export function mockConnection(
writeTransaction: stub(),
lastBookmark: stub(),
};
// @ts-ignore
const driver: Driver = {
close: spy(),
session: stub().returns(session),
Expand Down
Loading

0 comments on commit 3a39a45

Please sign in to comment.