Sha256: f90495e55399a9fc50afc31b1519930f58c65d9b0578064c32a34982a3627828

Contents?: true

Size: 738 Bytes

Versions: 25

Compression:

Stored size: 738 Bytes

Contents

require 'rails_helper'

module MessageTrain
  RSpec.describe Ignore do
    describe 'Model' do
      it { should belong_to :conversation }
      it { should belong_to :participant }
      it { should validate_presence_of :conversation }
      it { should validate_presence_of :participant }
    end
    describe 'Scopes and Methods' do
      include_context 'loaded site'
      describe '.find_all_by_participant' do
        subject { ignored_conversation.ignores.find_all_by_participant(first_user) }
        its(:first) { should be_a MessageTrain::Ignore }
      end
      describe '.conversations' do
        subject { MessageTrain::Ignore.conversations }
        it { should include ignored_conversation }
      end
    end
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
message_train-0.5.2 spec/models/message_train/ignore_spec.rb
message_train-0.5.1 spec/models/message_train/ignore_spec.rb
message_train-0.5.0 spec/models/message_train/ignore_spec.rb
message_train-0.4.6 spec/models/message_train/ignore_spec.rb
message_train-0.4.5 spec/models/message_train/ignore_spec.rb
message_train-0.4.4 spec/models/message_train/ignore_spec.rb
message_train-0.4.3 spec/models/message_train/ignore_spec.rb
message_train-0.4.2 spec/models/message_train/ignore_spec.rb
message_train-0.4.1 spec/models/message_train/ignore_spec.rb
message_train-0.4.0 spec/models/message_train/ignore_spec.rb
message_train-0.3.1 spec/models/message_train/ignore_spec.rb
message_train-0.3.0 spec/models/message_train/ignore_spec.rb
message_train-0.2.12 spec/models/message_train/ignore_spec.rb
message_train-0.2.11 spec/models/message_train/ignore_spec.rb
message_train-0.2.10 spec/models/message_train/ignore_spec.rb
message_train-0.2.9 spec/models/message_train/ignore_spec.rb
message_train-0.2.8 spec/models/message_train/ignore_spec.rb
message_train-0.2.7 spec/models/message_train/ignore_spec.rb
message_train-0.2.6 spec/models/message_train/ignore_spec.rb
message_train-0.2.5 spec/models/message_train/ignore_spec.rb