2017-05-31 09:43:19 -04:00
|
|
|
require_relative '../support/helpers/key_generator_helper'
|
|
|
|
|
2016-02-16 22:55:24 -05:00
|
|
|
FactoryGirl.define do
|
|
|
|
factory :key do
|
|
|
|
title
|
2017-05-31 09:43:19 -04:00
|
|
|
key { Spec::Support::Helpers::KeyGeneratorHelper.new(1024).generate + ' dummy@gitlab.com' }
|
2016-02-16 22:55:24 -05:00
|
|
|
|
2017-05-31 09:43:19 -04:00
|
|
|
factory :deploy_key, class: 'DeployKey'
|
2016-02-16 22:55:24 -05:00
|
|
|
|
|
|
|
factory :personal_key do
|
|
|
|
user
|
|
|
|
end
|
|
|
|
|
|
|
|
factory :another_key do
|
2017-05-31 09:43:19 -04:00
|
|
|
factory :another_deploy_key, class: 'DeployKey'
|
2016-02-16 22:55:24 -05:00
|
|
|
end
|
2017-04-05 02:22:28 -04:00
|
|
|
|
|
|
|
factory :write_access_key, class: 'DeployKey' do
|
|
|
|
can_push true
|
|
|
|
end
|
2016-02-16 22:55:24 -05:00
|
|
|
end
|
|
|
|
end
|