[go: nahoru, domu]

Skip to content

Commit

Permalink
E2E/integration tests: make sure tap teardown runs ✅
Browse files Browse the repository at this point in the history
may be related: tapjs/tapjs#1005
  • Loading branch information
derhuerst committed Feb 25, 2024
1 parent 6136097 commit 9eeafd0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/e2e/lib/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ import {ok, AssertionError} from 'assert';
import {DateTime} from 'luxon';
import * as a from 'assert';
import {createRequire} from 'module';
// Note: We *must* import tap up here, not just in the if(VCR_MODE) block below, because a) we can only use `require()` conditionally, not `import`; and b) requiring it below makes the teardown script behave differently.
// may be related: https://github.com/tapjs/tapjs/issues/1005
import tap from 'tap';
import {gunzipSync} from 'zlib';

const hour = 60 * 60 * 1000;
Expand Down Expand Up @@ -46,7 +49,6 @@ if (process.env.VCR_MODE && !process.env.VCR_OFF) {
const {Polly} = require('@pollyjs/core');
const NodeHttpAdapter = require('@pollyjs/adapter-node-http');
const FSPersister = require('@pollyjs/persister-fs');
const tap = require('tap');

// monkey-patch NodeHttpAdapter to handle gzipped responses properly
// todo: submit a PR
Expand Down

0 comments on commit 9eeafd0

Please sign in to comment.