tower-http icon indicating copy to clipboard operation
tower-http copied to clipboard

Constantify serve_{dir,file} test file paths and content

Open nc7s opened this issue 11 months ago • 2 comments

Motivation

Mainly a QoL change for downstream packagers, but might also prove useful for e.g. future refactors.

Currently we have to patch all those file paths to something exsistent, due to test-files/ not being included in crates.io releases, while the Debian Rust Team pulls Rust crate source from there.

Solution

With these constants we could change only them.

Test files are also changed to the same content, so one constant fits all.

nc7s avatar Jan 20 '25 16:01 nc7s

Hey. I understand you're trying to solve a real issue here, but I'm not a fan of this diff. Why do you run these tests when packaging?

jplatte avatar May 25 '25 18:05 jplatte

We frequently patch code in distros, so running tests there make sure our patches don't break things.

The diff - sure could be improved. Now that Debian's in freeze, it's not any urgent.

nc7s avatar May 26 '25 10:05 nc7s