Skip to content

Compression threshold changed in Express 4 middleware, breaks test #308

@hampelm

Description

@hampelm

Gzip compression is handled by compression in Express 4. By default, it only compresses responses >=1kb. The theory is that compressing smaller responses might actually increase the size.

The compression test we have now fails because the response is 14-ish bytes, and doesn't get compressed. Is there something we know will be more than 1kb in a test environment? Should we drop the test?

I tested manually with a larger request and compression is working.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions