Sha256: 81b18db01ce2206dd901d8263ed2c940307e55bbbe4dac8ce9b0c64b0ea3132e

Contents?: true

Size: 718 Bytes

Versions: 28

Compression:

Stored size: 718 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')

describe Receipt do
  
  before do
    @entity1 = Factory(:user)
    @entity2 = Factory(:user)
    @mail1 = @entity1.send_message(@entity2,"Body","Subject")   
  end
  
  it "should belong to a message" do
    assert @mail1.notification
  end
  
  it "should belong to a conversation" do
    assert @mail1.conversation    
  end
  
  it "should be able to be marked as unread" do
    @mail1.read.should==true
    @mail1.mark_as_unread
    @mail1.read.should==false
  end
  
  it "should be able to be marked as read" do
    @mail1.read.should==true
    @mail1.mark_as_unread
    @mail1.mark_as_read
    @mail1.read.should==true    
  end
  
  
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
mailboxer-0.2.0 spec/models/receipt_spec.rb
mailboxer-0.1.4 spec/models/receipt_spec.rb
mailboxer-0.1.3 spec/models/receipt_spec.rb
mailboxer-0.1.2 spec/models/receipt_spec.rb
mailboxer-0.1.1 spec/models/receipt_spec.rb
mailboxer-0.1.0 spec/models/receipt_spec.rb
mailboxer-0.0.16 spec/models/receipt_spec.rb
mailboxer-0.0.15 spec/models/receipt_spec.rb