Skip to content

Commit

Permalink
fix tests that are related
Browse files Browse the repository at this point in the history
  • Loading branch information
computermacgyver committed Aug 28, 2024
1 parent 36da4e5 commit 087c006
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/models/bot/smooch_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -796,15 +796,15 @@ def teardown

# Should not be a submission shortcut
message = {"text": "abc"}
assert_equal(false, Bot::Smooch::is_a_shortcut_for_submission(state,message), "Unexpected shortcut"
assert_equal(false, Bot::Smooch::is_a_shortcut_for_submission(state,message), "Unexpected shortcut")

# Should be a submission shortcut
message = {"text": "abc http://example.com"}
assert_equal(true, Bot::Smooch::is_a_shortcut_for_submission(state,message), "Missed URL shortcut"
assert_equal(true, Bot::Smooch::is_a_shortcut_for_submission(state,message), "Missed URL shortcut")

# Should be a submission shortcut
message = {"text": "abc", "mediaUrl": "not blank"}
assert_equal(true, Bot::Smooch::is_a_shortcut_for_submission(state,message), "Missed media shortcut"
assert_equal(true, Bot::Smooch::is_a_shortcut_for_submission(state,message), "Missed media shortcut")

Bot::Smooch.unstubs(:is_v2?)
end
Expand Down

0 comments on commit 087c006

Please sign in to comment.