Add tests for rest adapter

This adds tests for `RestAdapter`.
100% coverage.