added tests

This commit is contained in:
Hauke Klement
2015-02-23 17:37:48 +01:00
parent f3c5d17662
commit 821b911ebb

View File

@ -107,6 +107,13 @@ describe Lti do
let(:consumer) { FactoryGirl.create(:consumer) }
let(:score) { 0.5 }
context 'with an invalid score' do
it 'raises an exception' do
expect { controller.send(:send_score, Lti::MAXIMUM_SCORE * 2) }.to raise_error(Lti::Error)
end
end
context 'with an valid score' do
context 'with a tool provider' do
before(:each) do
controller.session[:consumer_id] = consumer.id
@ -152,6 +159,7 @@ describe Lti do
end
end
end
end
describe '#store_lti_session_data' do
let(:parameters) { {} }