Add a new BaseResource model that will be used by all API models.

The BaseResource model provides all the common functionality for dealing
with requests and parsing results, ensuring a model is ready to use (has
its data fetched) before we do anything with it, and being able to
ensure it's created before using it. These models have a concept of a
parent resource that they're under (for example, a diff being under a
review draft).

This change just introduces this model and a suite of unit tests for it.
We'll move over to this in subsequent commits.