Skip to content

Commit

Permalink
Test Action Models error message for unneeded namespaces (#1102)
Browse files Browse the repository at this point in the history
* Write test for Action Models error message

* Fixing Standard Ruby
  • Loading branch information
gazayas authored Oct 19, 2023
1 parent 60d34c0 commit cfe753d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/system/action_models_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ def setup

# targets-many action
if defined?(Projects::ArchiveAction)
# This error message is displayed for all actions, not just `targets-many`.
test "the proper error message is displayed for unneeded namespaces" do
output = `bin/super-scaffold action-model:targets-many Project::Publish Project Team`
assert output.include?("When creating an Action Model, you don't have to namespace the action")
end

test "developers can archive a single project" do
login_as(@jane, scope: :user)
visit account_team_path(@jane.current_team)
Expand Down

0 comments on commit cfe753d

Please sign in to comment.