From 20ab9c41b7b9537f81c7b47558e714441cc08cab Mon Sep 17 00:00:00 2001 From: Christian Murphy Date: Mon, 4 Nov 2019 09:32:40 -0700 Subject: [PATCH] test: cleanup type tests --- package.json | 7 ++++--- tsconfig.json | 4 ---- tslint.json | 10 +--------- unist-util-is-test.ts | 7 +------ 4 files changed, 6 insertions(+), 22 deletions(-) diff --git a/package.json b/package.json index d139aa8..9f0a61d 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,8 @@ "bugs": "https://github.com/syntax-tree/unist-util-is/issues", "author": "Titus Wormer (https://wooorm.com)", "contributors": [ - "Titus Wormer (https://wooorm.com)" + "Titus Wormer (https://wooorm.com)", + "Christian Murphy " ], "files": [ "index.js", @@ -28,15 +29,15 @@ "types": "index.d.ts", "dependencies": {}, "devDependencies": { + "@types/mdast": "^3.0.3", "browserify": "^16.0.0", - "dtslint": "^0.9.0", + "dtslint": "^1.0.2", "nyc": "^14.0.0", "prettier": "^1.0.0", "remark-cli": "^7.0.0", "remark-preset-wooorm": "^6.0.0", "tape": "^4.0.0", "tinyify": "^2.0.0", - "typescript": "^3.5.3", "unified": "^8.3.2", "xo": "^0.24.0" }, diff --git a/tsconfig.json b/tsconfig.json index 3d5c8e7..57dc9a1 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -2,10 +2,6 @@ "compilerOptions": { "lib": ["es2015"], "strict": true, - "noImplicitAny": true, - "noImplicitThis": true, - "strictNullChecks": true, - "strictFunctionTypes": true, "baseUrl": ".", "paths": { "unist-util-is": ["index.d.ts"], diff --git a/tslint.json b/tslint.json index aa59581..70c4494 100644 --- a/tslint.json +++ b/tslint.json @@ -1,15 +1,7 @@ { "extends": "dtslint/dtslint.json", "rules": { - "callable-types": false, - "max-line-length": false, - "no-redundant-jsdoc": false, - "no-void-expression": false, - "only-arrow-functions": false, "semicolon": false, - "unified-signatures": false, - "whitespace": false, - "interface-over-type-literal": false, - "no-unnecessary-generics": false + "whitespace": false } } diff --git a/unist-util-is-test.ts b/unist-util-is-test.ts index c3c0235..3ec9946 100644 --- a/unist-util-is-test.ts +++ b/unist-util-is-test.ts @@ -1,15 +1,10 @@ import {Node, Parent} from 'unist' +import {Heading} from 'mdast' import unified = require('unified') import is = require('unist-util-is') import convert = require('unist-util-is/convert') /*=== setup ===*/ -interface Heading extends Parent { - type: 'heading' - depth: number - children: Node[] -} - interface Element extends Parent { type: 'element' tagName: string