Files
fizzy/test/models/bubble/assignable_test.rb
T
Kevin McConnell 6157d8b4bd Start watching when participating on a bubble
If you're added as an assignee, or if you comment, then your watching
preference will be toggled on.
2025-02-26 10:53:03 +00:00

16 lines
468 B
Ruby

require "test_helper"
class Bubble::AssignableTest < ActiveSupport::TestCase
test "assigning a user makes them watch the bubble" do
assert_not bubbles(:layout).assigned_to?(users(:kevin))
bubbles(:layout).set_watching(users(:kevin), false)
with_current_user(:jz) do
bubbles(:layout).toggle_assignment(users(:kevin))
end
assert bubbles(:layout).assigned_to?(users(:kevin))
assert bubbles(:layout).watched_by?(users(:kevin))
end
end