Skip to content

Commit

Permalink
Use different integration testing strategies depending on API consumer
Browse files Browse the repository at this point in the history
  • Loading branch information
Laila Winner committed Oct 30, 2015
1 parent 4b3cd33 commit 3e2c9db
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion best-practices/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -335,8 +335,11 @@ Ruby JSON APIs

* Follow Heroku's [HTTP API Design Guide]
* Use a fast JSON parser, e.g. [`oj`][oj]
* Write [request specs] for your API endpoints
* Write integration tests for your API endpoints. When the primary consumer of
your API is an in-app JavaScript client, write [feature specs]. Otherwise
write [request specs].

[HTTP API Design Guide]: https://github.com/interagent/http-api-design
[oj]: https://github.com/ohler55/oj
[feature specs]: https://www.relishapp.com/rspec/rspec-rails/docs/feature-specs/feature-spec
[request specs]: https://www.relishapp.com/rspec/rspec-rails/docs/request-specs/request-spec

1 comment on commit 3e2c9db

@boddhisattva
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@malandrina Could you please elaborate more on what do you mean by an in-app Javascript client ? What are your thoughts on including an e.g., of the same in the guideline to help people of varying skill level(like me) to better understand this ?

Please sign in to comment.