Log bug for RSpec?
- Dominant language
- Ruby
- Stars
- 0
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
Not an issue with this codebase (presumably) but saving here for logging later:
This passes intermittently*
```RSpec.describe Message do
describe 'validations' do
it { is_expected.to belong_to :user }
it { is_expected.to have_many :message_recipients }
it { is_expected.to have_many(:recipient_lists).through(:messages_recipient_list) }
it { is_expected.to have_many(:recipients).through(:message_recipients) }
it { is_expected.to validate_presence_of :content }
it { is_expected.to validate_presence_of :status }
end
end```
but when the check for `recipient_lists` is _after_ the check for `recipients` the test fails with `Expected Message to have a has_many association called recipient_lists through messages_recipient_list (Could not find the association :messages_recipient_list in model Message)`
```RSpec.describe Message do
describe 'validations' do
it { is_expected.to belong_to :user }
it { is_expected.to have_many :message_recipients }
it { is_expected.to have_many(:recipients).through(:message_recipients) }
it { is_expected.to have_many(:recipient_lists).through(:messages_recipient_list) }
it { is_expected.to validate_presence_of :content }
it { is_expected.to validate_presence_of :status }
end
end```
* when running in the context of the whole suite, this sometimes fails, sometimes does not 🤷
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.