context 'when user is added to course team' do
      it 'it throws error when user added to course Team is not defined' do
        allow(User).to receive(:find_by).with(name: student1.name).and_return(student1)
        allow(Team).to receive(:find).with('5').and_return(team5)
        allow(CourseTeam).to receive(:find).with('5').and_return(team5)