deno-libs/http_compression

Add tests

talentlessguy opened this issue · 1 comments

I don't know why but using either std/http, node_http or tinyhttp + superdeno / superfetch fails in any case with leak errors:


  compression algorithms support
  • should support gzip

running 1 test from file:///home/v1rtl/Coding/deno-libs/compress/tests/compress.test.ts
test compression algorithms support > should support gzip ... FAILED (12ms)
lol

failures:

compression algorithms support > should support gzip
AssertionError: Test case is leaking async ops.
Before:
  - dispatched: 0
  - completed: 0
After:
  - dispatched: 5
  - completed: 3

Make sure to await all promises returned from Deno APIs before
finishing test case.
    at assert (deno:runtime/js/06_util.js:33:13)
    at asyncOpSanitizer (deno:runtime/js/40_testing.js:34:7)
    at async resourceSanitizer (deno:runtime/js/40_testing.js:58:7)
    at async exitSanitizer (deno:runtime/js/40_testing.js:85:9)
    at async runTest (deno:runtime/js/40_testing.js:199:7)
    at async Object.runTests (deno:runtime/js/40_testing.js:244:7)
    at async file:///home/v1rtl/Coding/deno-libs/compress/$deno$test.js:1:1

failures:

        compression algorithms support > should support gzip

test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out (717ms)

I would be glad if someone adds tests for compression that will work. Doesn't matter which testing tools, it should just work.

deno test --allow-net --allow-read passes with no issues once I updated the file sizes as in PR #4 . This issue should be able to be closed.