spec/lita/handlers/markov_spec.rb in lita-markov-1.2.0 vs spec/lita/handlers/markov_spec.rb in lita-markov-1.2.1

- old
+ new

@@ -27,9 +27,18 @@ 'I love pancakes.' ] expect(possible_replies.any? { |r| reply.include?(r) }).to eql true end + it 'will also accept @-names' do + send_message 'I like cookies.' + + send_command "#{robot.name} markov @#{user.mention_name}" + + expect(replies.count).to eql 1 + expect(replies[0]).to include('I like cookies.') + end + it "will complain if the user hasn't said anything" do send_command "#{robot.name} markov #{user.mention_name}" expect(replies.count).to eql 1 expect(replies[0]).to eql "Looks like Test User hasn't said anything!"