Hide score button if exercise has no tests

We check for all teacher-defined assessments (linter and unit tests) to determine whether scoring should be possible
This commit is contained in:
Janis4411
2022-08-08 10:37:29 +02:00
committed by Sebastian Serth
parent ba5918b4ca
commit e0c2c7b806
8 changed files with 97 additions and 8 deletions

View File

@ -6,7 +6,10 @@ describe ExercisesController do
let(:exercise) { create(:dummy) }
let(:user) { create(:admin) }
before { allow(controller).to receive(:current_user).and_return(user) }
before do
create(:test_file, context: exercise)
allow(controller).to receive(:current_user).and_return(user)
end
describe 'PUT #batch_update' do
let(:attributes) { {public: 'true'} }