diff options
author | Sanad Liaquat <sliaquat@gitlab.com> | 2019-07-25 06:08:23 +0000 |
---|---|---|
committer | Sanad Liaquat <sliaquat@gitlab.com> | 2019-07-25 06:08:23 +0000 |
commit | a5eaefc9027696fc65b7d51251902e013c14d161 (patch) | |
tree | b3e857e87f29dad668bbf9b4dfe0903fc759b880 /qa | |
parent | 046c85ed603f8fb581b1be71a5de5525e24a5fbb (diff) | |
parent | 657a5cc9d5df9eb4607d360b57d499c896fe1f73 (diff) | |
download | gitlab-ce-a5eaefc9027696fc65b7d51251902e013c14d161.tar.gz |
Merge branch 'sl-qa-staging-63-spam-issue-fix-ce' into 'master'
CE port of "Fix spam in issue creation by making project private"
See merge request gitlab-org/gitlab-ce!30997
Diffstat (limited to 'qa')
-rw-r--r-- | qa/qa/page/project/new.rb | 2 | ||||
-rw-r--r-- | qa/qa/resource/project.rb | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/qa/qa/page/project/new.rb b/qa/qa/page/project/new.rb index 0918445d119..64aab9be056 100644 --- a/qa/qa/page/project/new.rb +++ b/qa/qa/page/project/new.rb @@ -59,7 +59,7 @@ module QA end def set_visibility(visibility) - choose visibility + choose visibility.capitalize end def click_github_link diff --git a/qa/qa/resource/project.rb b/qa/qa/resource/project.rb index c0a6004fe27..93a82094776 100644 --- a/qa/qa/resource/project.rb +++ b/qa/qa/resource/project.rb @@ -8,6 +8,7 @@ module QA include Events::Project attr_writer :initialize_with_readme + attr_writer :visibility attribute :id attribute :name @@ -44,6 +45,7 @@ module QA @standalone = false @description = 'My awesome project' @initialize_with_readme = false + @visibility = 'public' end def name=(raw_name) @@ -60,7 +62,7 @@ module QA page.choose_test_namespace page.choose_name(@name) page.add_description(@description) - page.set_visibility('Public') + page.set_visibility(@visibility) page.enable_initialize_with_readme if @initialize_with_readme page.create_new_project end @@ -88,7 +90,7 @@ module QA post_body = { name: name, description: description, - visibility: 'public', + visibility: @visibility, initialize_with_readme: @initialize_with_readme } |