spec/models/invitation_spec.rb
Block has too many lines. [123/25] Open
Open
describe Invitation do
let(:user2) { build(:student, id: 2) }
let(:user3) { build(:student, id: 3) }
let(:assignment) { build(:assignment, id: 1) }
let(:team) { build(:assignment_team, id: 1, parent_id: 1) }
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Block has too many lines. [48/25] Open
Open
describe '#accept_invitation' do
context 'a user is not on a team and wishes to join a team with open slots' do
it 'places the user on a team and returns true' do
team_id = 0
allow(TeamsUser).to receive(:team_empty?).with(team_id).and_return(false)
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Block has too many lines. [31/25] Open
Open
describe '#update_users_topic_after_invite_accept' do
context 'the invited user was already in another team before accepting their invitation' do
it 'updates their team user mapping' do
updated_teams_user = TeamsUser.new
updated_teams_user.team_id = team.id
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.