diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-22 11:31:16 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-22 11:31:16 +0000 |
commit | 905c1110b08f93a19661cf42a276c7ea90d0a0ff (patch) | |
tree | 756d138db422392c00471ab06acdff92c5a9b69c /spec/factories/boards.rb | |
parent | 50d93f8d1686950fc58dda4823c4835fd0d8c14b (diff) | |
download | gitlab-ce-905c1110b08f93a19661cf42a276c7ea90d0a0ff.tar.gz |
Add latest changes from gitlab-org/gitlab@12-4-stable-ee
Diffstat (limited to 'spec/factories/boards.rb')
-rw-r--r-- | spec/factories/boards.rb | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/spec/factories/boards.rb b/spec/factories/boards.rb index a5aff5c7504..a201ca94380 100644 --- a/spec/factories/boards.rb +++ b/spec/factories/boards.rb @@ -3,11 +3,11 @@ FactoryBot.define do factory :board do transient do - project nil - group nil - project_id nil - group_id nil - parent nil + project { nil } + group { nil } + project_id { nil } + group_id { nil } + resource_parent { nil } end after(:build, :stub) do |board, evaluator| @@ -19,9 +19,9 @@ FactoryBot.define do board.project = evaluator.project elsif evaluator.project_id board.project_id = evaluator.project_id - elsif evaluator.parent - id = evaluator.parent.id - evaluator.parent.is_a?(Group) ? board.group_id = id : evaluator.project_id = id + elsif evaluator.resource_parent + id = evaluator.resource_parent.id + evaluator.resource_parent.is_a?(Group) ? board.group_id = id : evaluator.project_id = id else board.project = create(:project, :empty_repo) end |