ol-infrastructure
ol-infrastructure copied to clipboard
Write a simple unit test suite for Fastly changes
Description/Context
Right now, when we make VCL changes to Fastly, we have very little beyond manual testing to ensure that we're not impacting our operational readiness.
For instance, Fastly had a default cap on the size of transfers at 2G, but we had a file in OCW that was larger than that, so the users were getting HTTP 503.
Plan/Design
Build a simple unit test suite that could be trivially run after any Fastly VCL changes were made.
One possible idea for implementation would be Pytest unit tests using request.
Some initial cases might include:
- Can we do a simple HTTPS get from an endpoint?
- Can we transfer a file >2G?
- TODO needs more test cases!
Another possible implementation (potentially better) would be user level interaction testing using playwright.