From b4a54522ec5915c66d24b3f13cf03fbfdb895d3d Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Mon, 6 Apr 2020 13:33:15 +0530 Subject: [PATCH] make test runner work again --- package.json | 14 +++++++++++++- yarn.lock | 7 +++++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index b0eec0399..a24dc148e 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,8 @@ }, "scripts": { "build": "make tsc", - "pretty": "prettier --config .prettierrc --write src" + "pretty": "prettier --config .prettierrc --write src", + "test": "ava" }, "files": [ "AUTHORS", @@ -69,10 +70,21 @@ "webpack-merge": "^4.2.2" }, "dependencies": { + "@ava/typescript": "^1.1.1", "axios": "^0.19.2", "big-integer": "^1.6.48", "idb-bridge": "^0.0.15", "qrcode-generator": "^1.4.3", "source-map-support": "^0.5.12" + }, + "ava": { + "files": [ + "src/**/*-test.{js,ts}" + ], + "typescript": { + "rewritePaths": { + "src/": "dist/node/" + } + } } } diff --git a/yarn.lock b/yarn.lock index 5a72c927a..7ae70a064 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,13 @@ # yarn lockfile v1 +"@ava/typescript@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@ava/typescript/-/typescript-1.1.1.tgz#3dcaba3aced8026fdb584d927d809752854dc6e6" + integrity sha512-KbLUAe2cWXK63WLK6LnOJonjwEDU/8MNXCOA1ooX/YFZgKRmeAD1kZu+2K0ks5fnOCEcckNQAooyBNGdZUmMQA== + dependencies: + escape-string-regexp "^2.0.0" + "@babel/code-frame@^7.0.0", "@babel/code-frame@^7.5.5": version "7.5.5" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.5.5.tgz#bc0782f6d69f7b7d49531219699b988f669a8f9d"