Add tests for performance

These should be useful for anyone experimenting with making the polyfill perform faster.