Skip to content

Commit 6e92686

Browse files
authored
Ajv updated to 7.0 -- update the tests of dependents (DefinitelyTyped#50156)
* Ajv updated to 7.0 -- update the test It now needs to be imported with default imports. * Update index.d.ts too, require TS 3.8 Looks like ajv@7 requires TS 3.8 or higher. Also update ajv-errors-tests options passed to Ajv.
1 parent 1ddecfd commit 6e92686

File tree

8 files changed

+13
-12
lines changed

8 files changed

+13
-12
lines changed

types/ajv-async/ajv-async-tests.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Ajv from 'ajv';
1+
import Ajv from 'ajv';
22
import setupAsyncToAJV = require('ajv-async');
33

44
const ajv = new Ajv();

types/ajv-async/index.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// Project: https://github.com/epoberezkin/ajv-async#readme
33
// Definitions by: es <https://github.com/dmitriismitnov>
44
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
5-
// TypeScript Version: 2.2
5+
// TypeScript Version: 3.8
66

7-
import { Ajv } from 'ajv';
7+
import Ajv from 'ajv';
88

99
declare function ajvAsync(ajv: Ajv): Ajv;
1010
export = ajvAsync;

types/ajv-bsontype/ajv-bsontype-tests.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Ajv from 'ajv';
1+
import Ajv from 'ajv';
22
import ajvBsontype = require('ajv-bsontype');
33

44
const ajv = new Ajv();

types/ajv-bsontype/index.d.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22
// Project: https://github.com/BoLaMN/ajv-bsontype#readme
33
// Definitions by: Alex <https://github.com/adjerbetian>
44
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
5+
// Minimum TypeScript Version: 3.8
56

6-
import { Ajv } from 'ajv';
7+
import Ajv from 'ajv';
78

89
declare function ajvBsontype(ajv: Ajv): Ajv;
910
export = ajvBsontype;

types/ajv-errors/ajv-errors-tests.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import * as Ajv from "ajv";
1+
import Ajv from "ajv";
22
import AjvErrors = require("ajv-errors");
33

4-
const ajv = new Ajv({allErrors: true, jsonPointers: true});
4+
const ajv = new Ajv({ allErrors: true });
55
AjvErrors(ajv);

types/ajv-errors/index.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// Project: https://github.com/epoberezkin/ajv-errors
33
// Definitions by: Afshawn Lotfi <https://github.com/afshawnlotfi>
44
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
5-
// TypeScript Version: 2.2
5+
// TypeScript Version: 3.8
66

7-
import { Ajv } from "ajv";
7+
import Ajv from "ajv";
88

99
/**
1010
*

types/ajv-merge-patch/ajv-merge-patch-tests.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Ajv from "ajv";
1+
import Ajv from "ajv";
22

33
import ajvMergePatch = require("ajv-merge-patch");
44

types/ajv-merge-patch/index.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// Project: https://github.com/epoberezkin/ajv-merge-patch#readme
33
// Definitions by: Zhu Zijia <https://github.com/littlepiggy03>
44
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
5-
// TypeScript Version: 2.2
5+
// TypeScript Version: 3.8
66

7-
import { Ajv } from "ajv";
7+
import Ajv from "ajv";
88

99
declare function ajvMergePatch(ajv: Ajv): void;
1010

0 commit comments

Comments
 (0)