Sha256: 5b74dc94b347dc1cce92c4f46f4bf3a223ec2659af707e9d4bbe03714f3f1ccb
Contents?: true
Size: 428 Bytes
Versions: 75
Compression:
Stored size: 428 Bytes
Contents
require File.expand_path('../abstract_unit', __FILE__) class TestValidations < ActiveSupport::TestCase fixtures :students, :dorms, :rooms, :room_assignments def test_uniqueness_validation_persisted room_assignment = RoomAssignment.find([1, 1, 1]) assert(room_assignment.valid?) room_assignment = RoomAssignment.new(:student_id => 1, :dorm_id => 1, :room_id => 2) assert(!room_assignment.valid?) end end
Version data entries
75 entries across 75 versions & 1 rubygems