def test_denying_sfx(self, mock_present_users):
     result = FeedbackRouter(
         "not_streamlord",
         "soundeffect",
         [YOUTUBE_URL, "storm_seeker", "00:01", "00:04"],
     ).route()
     assert SoundeffectRequest.count() == 1
     result = FeedbackRouter("beginbotbot", "deny",
                             ["not_streamlord"]).route()
     assert SoundeffectRequest.count() == 0
 def test_requesting_sfx(self):
     result = FeedbackRouter(
         "beginbotbot",
         "soundeffect",
         [YOUTUBE_URL, "storm_seeker", "00:01", "00:04"],
     ).route()
     assert SoundeffectRequest.count() == 1
 def test_requesting_sfx(self):
     result = FeedbackRouter(
         "beginbotbot",
         "soundeffect",
         [YOUTUBE_URL, "@cool_user", "00:01", "00:04"],
     ).route()
     assert SoundeffectRequest.count() == 1
     sfx = SoundeffectRequest.last()
     assert sfx["command"] == "cool_user"
 def test_requesting_sfx_with_no_timestamps(self):
     result = FeedbackRouter(
         "cool_user",
         "soundeffect",
         [YOUTUBE_URL],
     ).route()
     assert SoundeffectRequest.count() == 1
     sfx = SoundeffectRequest.last()
     assert sfx["command"] == "cool_user"
     assert sfx["requester"] == "cool_user"
 def test_soundeffect_request_with_no_args(self):
     result = FeedbackRouter(
         "fake_user",
         "soundeffect",
         [],
     ).route()
     assert (
         result ==
         "@fake_user Correct Syntax: !soundeffect YOUTUBE_URL COMMAND_NAME 00:01 00:05 - Must be less than 5 second"
     )
 def test_submitting_and_deleting_issue(self):
     result = FeedbackRouter(
         "fake_user",
         "issue",
         [],
     ).route()
     assert result == "@fake_user Must include a description of the !issue"
     assert Issue.count() == 0
     result = FeedbackRouter(
         "not_streamlord",
         "issue",
         ["THIS THING DOESN'T WORK"],
     ).route()
     assert Issue.count() == 1
     result = FeedbackRouter("beginbotbot", "issues").route()
     assert result == ["@not_streamlord ID: 1 - THIS THING DOESN'T WORK"]
     FeedbackRouter(
         "beginbotbot",
         "delete_issue",
         ["not_streamlord"],
     ).route()
     assert Issue.count() == 0