This was fine when the library was smaller, but as the library grows the tests for that file are also growing. Ideally, there should be two files; one that manages rendering, and one that extracts classes/etc.