Skip to content
Browse files

removed all carrier artefacts

  • Loading branch information...
1 parent ccaeb08 commit 7917c0d880aff9c66e0c520367793ac1be11c9a5 @stanislaw committed Sep 3, 2011
View
22 spec/carrier/app/models/message_scopes_spec.rb
@@ -1,22 +0,0 @@
-describe Carrier::Message do
- concern "Scopes" do
- before(:all) do
- Carrier::Message.delete_all
- Carrier::Chain.delete_all
- end
-
- specify {
- Message.count.should == 0
- Chain.count.should == 0
- Message.for_or_by(User.first).size.should == 0
- create(:first_message)
- Message.for(User.first).size.should == 0
- Message.by(User.first).size.should == 1
- Message.for_or_by(User.first).size.should == 1
- create(:second_message)
- Message.for(User.first).size.should == 1
- Message.by(User.first).size.should == 1
- Message.for_or_by(User.first).size.should == 2
- }
- end
-end
View
36 spec/carrier/app/models/message_spec.rb
@@ -1,36 +0,0 @@
-require 'dummy_spec_helper'
-
-describe Carrier::Message do
- describe 'Carrier::Message class' do
- subject {Carrier::Message}
- its(:table_name) { should == Carrier.config.models.table_for(:message) }
-
- describe "#find_recipients" do
- it "should return all recipients" do
- pending
- end
- end
- end
-
- it { should belong_to(:chain) }
-
- it "should serialize .recipients field" do
- subject.recipients.should == []
- end
-
- concern "Validations" do
- it "should not save messages with empty .content field" do
- lambda {
- subject.content = ''
- subject.save!
- }.should raise_error(ActiveRecord::RecordInvalid)
- end
- it "should not save messages with wrong recipients" do
- lambda {
- subject.sender = 1
- subject.content = 'something'
- subject.save!
- }.should raise_error(ActiveRecord::RecordInvalid)
- end
- end
-end
View
1 spec/dummy/app/views/layouts/application.html.erb
@@ -10,7 +10,6 @@
<%= yield %>
-<%= link_to 'Carrier', '/carrier' %>
<%= link_to 'Sign out', destroy_user_session_path, :method => :delete %>
</body>
</html>

0 comments on commit 7917c0d

Please sign in to comment.
Something went wrong with that request. Please try again.