Every single optimisation pass needs tests covering:
- The most basic case where optimisation should happen. Verify that it does.
- A more complex "real world" example where optimisation should happen. Verify that it does.
If possible:
- A case where optimisation should not happen but seems likely to be miss-optimised, verify that it does not.