OpenProject is the leading open source project management software.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
openproject/spec/models/version_setting_spec.rb

35 lines
889 B

require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
describe VersionSetting do
let(:version_setting) { FactoryGirl.build(:version_setting) }
it { should belong_to(:project) }
it { should belong_to(:version) }
it { VersionSetting.column_names.should include("display") }
describe "Instance Methods" do
describe "WITH display set to left" do
before(:each) do
version_setting.display_left!
end
it { version_setting.display_left?.should be_true }
end
describe "WITH display set to right" do
before(:each) do
version_setting.display_right!
end
it { version_setting.display_right?.should be_true }
end
describe "WITH display set to none" do
before(:each) do
version_setting.display_none!
end
it { version_setting.display_none?.should be_true }
end
end
end