Bureaucrat.Macros (bureaucrat v0.2.10)
Implements Phoenix.ConnTest
macros with &Bureaucrat.Helpers.doc/1
support.
When Phoenix.ConnTest
macros (get, post, put...) are called, doc
helper is automatically called after.
If you don't wish to document a certain request, use get_undocumented
or any other _undocumented
macro.
It automatically skips documentation if halted by a Plug.
When a request is called from inside a private function instead of a test block, Bureaucrat
can't
find the test name to use on the documentation, and raises. In this case, use the _undocumented
version to bypass the documentation, or send the request from the test block instead of private function.
- Automatically documents: get, post, put, patch and delete requests
- Skips documentation for: options, connect, trace and head requests
- Implements: get_undocumented, post_undocumented, put_undocumented, patch_undocumented and delete_undocumented.
usage
Usage
On ConnCase
file, change this
import Phoenix.ConnTest
To
import Phoenix.ConnTest, only: :functions
import Bureaucrat.Helpers
import Bureaucrat.Macros
Link to this section Summary
Functions
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests
Link to this section Functions
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request with documentation. Documents: get, post, put, patch and delete requests.
Dispatches test request without documentation. Implements: get_undocumented, post_undocumented, put_undocumented, ..., macros to skip doc.
Dispatches test request without documentation. Skips documentation for: options, connect, trace and head requests