Angband
Rack middleware that renders the Gherkin features of your application.
Configuration
-
Specify the applicable feature files:
require 'angband/documentation' use Angband::Documentation do |docs| docs.configure Dir['features/**/*.feature'] end
-
Annotate your features with the URI path to which they apply:
@/api/status Feature: Status of the API
Use regular expressions to match variable paths:
@/api/message/\d+ Feature: Read a single message
-
Configure your application to respond successfully to an HTTP
OPTIONS
request.
While this middleware sets the response Content-Type
and body, any other headers
should be added by the application,
e.g. the Allow
header.