Skip to content

Commit

Permalink
change test so that students can see the input in the test readouts
Browse files Browse the repository at this point in the history
  • Loading branch information
kthffmn committed Oct 7, 2014
1 parent 8f7ad2d commit da4d5ea
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions spec/email_parser_spec.rb
Original file line number Diff line number Diff line change
@@ -1,26 +1,20 @@
describe "EmailParser" do
describe '#parser' do
it "parses CSV emails" do
emails = "[email protected], [email protected]"
expect(EmailParser.new(emails).parse).to eq(["[email protected]", "[email protected]"])
expect(EmailParser.new("[email protected], [email protected]").parse).to eq(["[email protected]", "[email protected]"])
end

it "parses space delimited emails" do
emails = "[email protected] [email protected]"

expect(EmailParser.new(emails).parse).to eq(["[email protected]", "[email protected]"])
expect(EmailParser.new("[email protected] [email protected]").parse).to eq(["[email protected]", "[email protected]"])
end

it "parses both CSV and spac delimited emails" do
it "parses both CSV and space delimited emails" do
emails = "[email protected], [email protected] [email protected], [email protected]"

expect(EmailParser.new(emails).parse).to eq(["[email protected]", "[email protected]","[email protected]", "[email protected]"])
end

it 'parses and removes duplicate emails' do
emails = "[email protected], [email protected]"

expect(EmailParser.new(emails).parse).to eq(["[email protected]"])
expect(EmailParser.new("[email protected], [email protected]").parse).to eq(["[email protected]"])
end
end
end

0 comments on commit da4d5ea

Please sign in to comment.