From: 
Subject: Debian changes

The Debian packaging of node-idb-keyval is maintained in git, using a workflow
similar to the one described in dgit-maint-merge(7).
The Debian delta is represented by this one combined patch; there isn't a
patch queue that can be represented as a quilt series.

A detailed breakdown of the changes is available from their canonical
representation -- git commits in the packaging repository.
For example, to see the changes made by the Debian maintainer in the first
upload of upstream version 1.2.3, you could use:

    % git clone https://git.dgit.debian.org/node-idb-keyval
    % cd node-idb-keyval
    % git log --oneline 1.2.3..debian/1.2.3-1 -- . ':!debian'

(If you have dgit, use `dgit clone node-idb-keyval`, rather than plain `git clone`.)

We don't use debian/source/options single-debian-patch because it has bugs.
Therefore, NMUs etc. may nevertheless have made additional patches.

---

diff --git a/generic-tsconfig.json b/generic-tsconfig.json
index 3e64581..372234e 100644
--- a/generic-tsconfig.json
+++ b/generic-tsconfig.json
@@ -3,7 +3,7 @@
     "target": "ESNext",
     "module": "esnext",
     "strict": true,
-    "moduleResolution": "node",
+    "moduleResolution": "bundler",
     "composite": true,
     "declarationMap": false,
     "rootDir": "./",
diff --git a/test/index.ts b/test/index.ts
index b5b4546..eb88c17 100644
--- a/test/index.ts
+++ b/test/index.ts
@@ -14,8 +14,8 @@ import {
   update,
   getMany,
   delMany,
-} from '../src';
-import { assert as typeAssert, IsExact } from 'conditional-type-checks';
+} from 'idb-keyval';
+import { assert as typeAssert, IsExact } from './type-checks';
 
 const { assert } = chai;
 mocha.setup('tdd');
@@ -549,5 +549,13 @@ mocha.setup('tdd');
     });
   });
 
-  mocha.run();
+  const failures: string[] = [];
+  const runner = mocha.run((count) => {
+    fetch('/results', {
+      method: 'POST',
+      body: JSON.stringify({ failures: count, tests: runner.stats?.tests, errors: failures }),
+    });
+  }).on('fail', (test, error) => {
+    failures.push(`${test.fullTitle()}: ${error.stack || error.message}`);
+  });
 })();
diff --git a/test/mocha.d.ts b/test/mocha.d.ts
new file mode 100644
index 0000000..36c192a
--- /dev/null
+++ b/test/mocha.d.ts
@@ -0,0 +1 @@
+declare module 'mocha/mocha';
diff --git a/test/tsconfig.json b/test/tsconfig.json
index 67b50e0..178ced6 100644
--- a/test/tsconfig.json
+++ b/test/tsconfig.json
@@ -3,10 +3,10 @@
   "compilerOptions": {
     "esModuleInterop": true,
     "lib": ["esnext", "dom"],
-    "tsBuildInfoFile": "../.ts-tmp/.test.tsbuildinfo",
-    "declarationDir": "../dist/test",
-    "composite": true,
-    "rootDir": "../"
+    "types": ["mocha"],
+    "skipLibCheck": true,
+    "composite": false,
+    "declaration": false
   },
-  "include": ["**/*.ts", "../src/**/*.ts"]
+  "include": ["**/*.ts"]
 }
diff --git a/test/type-checks.ts b/test/type-checks.ts
new file mode 100644
index 0000000..9250b98
--- /dev/null
+++ b/test/type-checks.ts
@@ -0,0 +1,8 @@
+// Compile-time assertions used by the upstream tests.
+export type IsExact<T, U> =
+  (<V>() => V extends T ? 1 : 2) extends
+  (<V>() => V extends U ? 1 : 2) ? true : false;
+
+export function assert<T extends true>(value: T): void {
+  if (!value) throw new Error('Type assertion failed');
+}
