Roughly, the idea is that http queries are transformed into file queries
within http context. If found, the data file is served or not (404). This
translates into query response so that the code can actually complete as usual.
For sample use cases, see for examples:
- lister:
- loader-package:
- https://forge.softwareheritage.org/source/swh-loader-core/browse/package-loader/swh/loader/package/tests/test_gnu.py$198
- https://forge.softwareheritage.org/source/swh-loader-core/browse/package-loader/swh/loader/package/tests/test_npm.py$406
- https://forge.softwareheritage.org/source/swh-loader-core/browse/package-loader/swh/loader/package/tests/test_pypi.py$191
- https://forge.softwareheritage.org/source/swh-loader-core/browse/package-loader/swh/loader/package/tests/test_deposit.py$66-67
Note:
The fixture's name is not that good, if you have any better idea, now is the time ;)