Add tests
Some checks failed
/ Text (push) Failing after 15s
/ Checkout (push) Successful in 1m3s

This commit is contained in:
david 2024-07-22 22:40:56 +02:00
parent 363dfaa7d3
commit cdea0e1218
14 changed files with 116 additions and 52 deletions

View file

@ -24,7 +24,7 @@ class ChecklistsController < ApplicationController
@checklist = Checklist.new(checklist_params)
if @checklist.save
redirect_to [:edit, @checklist], notice: 'Checklist was successfully created.'
redirect_to @checklist, notice: 'Checklist was successfully created.'
else
render :new, status: :unprocessable_entity
end

View file

@ -42,7 +42,12 @@ class SuccessCriteriaController < ApplicationController
# DELETE /success_criteria/1
def destroy
@success_criterion.destroy!
redirect_to success_criteria_url, notice: 'Success criterion was successfully destroyed.', status: :see_other
respond_to do |format|
format.html do
redirect_to success_criteria_url, notice: 'Success criterion was successfully destroyed.', status: :see_other
end
format.turbo_stream
end
end
private