Sha256: 4d000f56dda61d3cbcf7d346134dae23b1c12ca8b33a6d4d203e4111d9301ffd
Contents?: true
Size: 650 Bytes
Versions: 13
Compression:
Stored size: 650 Bytes
Contents
require File.join(File.dirname(__FILE__), '../spec_helper.rb') describe Chat do before do @good_chat = "You: Hello\nMe: Hello back at ya!\nYou: Wanna go eat\nYou: Somehwere\nMe: Yes!" @bad_chat = "Rating: 4\nItem: Dyson\n\nThis should be the description." class Yellow; end Object.send(:remove_const, :Yellow) end should "detect a well-formed chat" do Chat.detect?(@good_chat).should.be.true end should "not detect a malformed chat" do Chat.detect?(@bad_chat).should.be.false end should "autodetect a well-formed chat" do PostType.auto_detect(@good_chat).should.be.kind_of Chat end end
Version data entries
13 entries across 13 versions & 1 rubygems