debian-mirror-gitlab/spec/factories/wikis.rb
2020-05-24 23:13:21 +05:30

21 lines
421 B
Ruby

# frozen_string_literal: true
FactoryBot.define do
factory :wiki do
transient do
container { association(:project, :wiki_repo) }
user { association(:user) }
end
initialize_with { Wiki.for_container(container, user) }
skip_create
factory :project_wiki do
transient do
project { association(:project, :wiki_repo) }
end
container { project }
end
end
end