2016-02-16 22:55:24 -05:00
|
|
|
FactoryGirl.define do
|
|
|
|
factory :group do
|
|
|
|
sequence(:name) { |n| "group#{n}" }
|
|
|
|
path { name.downcase.gsub(/\s/, '_') }
|
|
|
|
type 'Group'
|
2016-03-18 08:28:16 -04:00
|
|
|
|
|
|
|
trait :public do
|
|
|
|
visibility_level Gitlab::VisibilityLevel::PUBLIC
|
|
|
|
end
|
|
|
|
|
|
|
|
trait :internal do
|
|
|
|
visibility_level Gitlab::VisibilityLevel::INTERNAL
|
|
|
|
end
|
|
|
|
|
|
|
|
trait :private do
|
|
|
|
visibility_level Gitlab::VisibilityLevel::PRIVATE
|
|
|
|
end
|
2016-11-11 07:51:50 -05:00
|
|
|
|
|
|
|
trait :access_requestable do
|
|
|
|
request_access_enabled true
|
|
|
|
end
|
2016-02-16 22:55:24 -05:00
|
|
|
end
|
|
|
|
end
|