oxidecomputer / oxidecomputer/dropshot

Make header checks in dropshot::test_util configurable.

Open
#299 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
1.2k
Forks
104
Avg merge
1d 19h
Merged PRs (30d)
22

Description

Context: We require setting CORS headers as part of our Rest Server implementation. We have started a discussion about it in another issue on this repo.

We have set the response headers but it causes our unit tests to fail because the test_util is setup to panic if any extra headers are added to the response. Can we make this configurable?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in dropshot/test_util.rs around the header check linked in the issue, and inspect the existing test_util tests that exercise response headers. Make the rejection of extra headers configurable while preserving the current default behavior, then verify the relevant unit tests cover both configurations.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
api, testing
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.