From 6d28f427d89eb124f2ee65bcb79fd4da2c21e880 Mon Sep 17 00:00:00 2001 From: Maximilian Grundke Date: Wed, 25 Oct 2017 10:12:29 +0200 Subject: [PATCH] Add Ralf's comment to skipped tests --- spec/concerns/lti_spec.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/spec/concerns/lti_spec.rb b/spec/concerns/lti_spec.rb index a7028224..32d740aa 100644 --- a/spec/concerns/lti_spec.rb +++ b/spec/concerns/lti_spec.rb @@ -114,7 +114,7 @@ describe Lti do context 'when grading is not supported' do it 'returns a corresponding status' do - skip('todo') + skip('ralf: this does not work, since send_score pulls data from the database, which then returns an empty array. On this is called .first, which returns nil and lets the test fail. Before Toms changes, this was taken from the session, which could be mocked') expect_any_instance_of(IMS::LTI::ToolProvider).to receive(:outcome_service?).and_return(false) expect(controller.send(:send_score, submission.exercise_id, score, submission.user_id)[:status]).to eq('unsupported') end @@ -133,12 +133,12 @@ describe Lti do end it 'sends the score' do - skip('todo') + skip('ralf: this does not work, since send_score pulls data from the database, which then returns an empty array. On this is called .first, which returns nil and lets the test fail. Before Toms changes, this was taken from the session, which could be mocked') controller.send(:send_score, submission.exercise_id, score, submission.user_id) end it 'returns code, message, and status' do - skip('todo') + skip('ralf: this does not work, since send_score pulls data from the database, which then returns an empty array. On this is called .first, which returns nil and lets the test fail. Before Toms changes, this was taken from the session, which could be mocked') result = controller.send(:send_score, submission.exercise_id, score, submission.user_id) expect(result[:code]).to eq(response.response_code) expect(result[:message]).to eq(response.body)