• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Kikobeats / http-compression / 43631937944
94%

Build:
DEFAULT BRANCH: master
Ran 14 Nov 2026 07:25PM UTC
Jobs 3
Files 1
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

14 Nov 2026 07:24PM UTC coverage: 93.789% (-0.08%) from 93.865%
43631937944

push

github

web-flow
feat: compress at brotli 2 and gzip 2 by default (#25)

* feat: compress at brotli 2 and gzip 2 by default

The defaults were brotli 0 and gzip 1, picked by a benchmark score that
weighted 1/time and so always favoured the fastest level.

The benchmark now serves each payload through the middleware over HTTP,
adds the time to send the compressed body at a given bandwidth (100 Mbps
by default), and reports the highest level within 3% of the fastest on
every payload. Over HTML, Markdown, JavaScript, a 4.2MB JSON response
and a 2kB JSON response it picked brotli 2 and gzip 2 in 6 of 7 runs.
Brotli 2 compresses the 4.2MB JSON 17.09x against 7.26x at brotli 0 and
serves it in about half the time.

`level` now falls back to the default per key. A partial object such as
`{ gzip: 9 }` used to leave brotli without a quality, and every brotli
response then threw. `null` and `undefined` keys fall back too, and 0 is
kept.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test: lock a null per-key level to its default

A null brotli or gzip level is unset, same as a missing one. The suite only passed null as the whole level object, so replacing ?? with an undefined check stayed green.

* test: load ava's callable export under require()

AVA 8's require() returns the module namespace, so the suite threw "test is not a function" before any assertion ran. Use the default export, which is the test function on both the current and the previous major.

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

39 of 47 branches covered (82.98%)

Branch coverage included in aggregate %.

19 of 19 new or added lines in 1 file covered. (100.0%)

112 of 114 relevant lines covered (98.25%)

53.0 hits per line

Jobs
ID Job ID Ran Files Coverage
1 43631937944.1 14 Nov 2026 07:25PM UTC 1
93.79
GitHub Action Run
2 43631937944.2 14 Nov 2026 07:25PM UTC 1
93.79
GitHub Action Run
3 43631937944.3 14 Nov 2026 07:25PM UTC 1
93.79
GitHub Action Run
Source Files on build 43631937944
  • Tree
  • List 1
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #43631937944
  • a57f8e2a on github
  • Prev Build on master (#24384676432)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc