Sha256: 6c5843aaa113d38c2755332397c8626c9e3fce77265e8f7b26a6b98c3594c908

Contents?: true

Size: 713 Bytes

Versions: 6

Compression:

Stored size: 713 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.message
  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

6 entries across 6 versions & 1 rubygems

Version Path
mailboxer-0.0.14 spec/models/receipt_spec.rb
mailboxer-0.0.13 spec/models/receipt_spec.rb
mailboxer-0.0.12 spec/models/receipt_spec.rb
mailboxer-0.0.11 spec/models/receipt_spec.rb
mailboxer-0.0.10 spec/models/receipt_spec.rb
mailboxer-0.0.9 spec/models/receipt_spec.rb