Sha256: fe9ae9630a302bba02ae366f1e768074017088036b1c727a09cfa65107e02c9b
Contents?: true
Size: 590 Bytes
Versions: 137
Compression:
Stored size: 590 Bytes
Contents
require 'spec_helper' RSpec.describe AssignmentGroup, type: :model do let(:subject) { FactoryGirl.create(:assignment_group) } describe 'validations' do it { should validate_presence_of(:canvas_id) } it { should validate_uniqueness_of(:canvas_id) } end describe 'associations' do it do should belong_to(:course) .with_primary_key(:canvas_id) .with_foreign_key(:canvas_course_id) end it do should have_many(:assignments) .with_primary_key(:canvas_id) .with_foreign_key(:canvas_assignment_group_id) end end end
Version data entries
137 entries across 137 versions & 1 rubygems