Commit Graph

3 Commits

Author SHA1 Message Date
evazion
273be55de8 Upgrade to Ruby 3.0.2. 2021-09-21 02:56:23 -05:00
BrokenEagle
34ca33e22f Update should helper with more functionality
- Allow for different user levels by checking the CurrentUser variable
- Allow for other URL parameters other than the search parameters
-- This is needed on some controllers such as the comments controller
- Allow for delayed execution of lambda functions for item input
-- This is because the updated_at field isn't correct at the time
   that the input gets sent to the function
-- This prevented the right order from being tested
2020-07-27 19:29:21 +00:00
evazion
2b969646bc tests: add respond_to_search test helper.
Add a `respond_to_search` test helper for concisely testing that a
controller's index action correctly responds to a search. Usage:

    # Tests that `/tags.json?search[name]=touhou` returns the `touhou` tag.

    setup { @touhou = create(:tag, name: "touhou") }
    should respond_to_search(name: "touhou").with { @touhou }
2020-06-23 23:35:48 -05:00