Made the API tests a little easier to understand (hopefully)

Mostly by splitting them into multiple files.  There's more refactoring possible, but this should at least make things easier.