Files
codeocean/spec/helpers/exercise_helper_spec.rb
Hauke Klement 6fbeb574e3 added tests
2015-02-10 15:36:03 +01:00

16 lines
397 B
Ruby

require 'rails_helper'
describe ExerciseHelper do
describe '#embedding_parameters' do
let(:exercise) { FactoryGirl.build(:dummy) }
it 'contains the locale' do
expect(embedding_parameters(exercise)).to start_with("locale=#{I18n.locale}")
end
it 'contains the token' do
expect(embedding_parameters(exercise)).to end_with("token=#{exercise.token}")
end
end
end