gitlab-org--gitlab-foss/spec/models/protected_branch_spec.rb
Dmitriy Zaporozhets 98ee4a1fa7 Annotate models
2015-01-22 09:40:03 -08:00

27 lines
655 B
Ruby

# == Schema Information
#
# Table name: protected_branches
#
# id :integer not null, primary key
# project_id :integer not null
# name :string(255) not null
# created_at :datetime
# updated_at :datetime
# developers_can_push :boolean default(FALSE), not null
#
require 'spec_helper'
describe ProtectedBranch do
describe 'Associations' do
it { should belong_to(:project) }
end
describe "Mass assignment" do
end
describe 'Validation' do
it { should validate_presence_of(:project) }
it { should validate_presence_of(:name) }
end
end