diff options
Diffstat (limited to 'qa/qa/page/organization')
-rw-r--r-- | qa/qa/page/organization/new.rb | 25 | ||||
-rw-r--r-- | qa/qa/page/organization/show.rb | 18 |
2 files changed, 43 insertions, 0 deletions
diff --git a/qa/qa/page/organization/new.rb b/qa/qa/page/organization/new.rb new file mode 100644 index 00000000000..c72a3e6d1b4 --- /dev/null +++ b/qa/qa/page/organization/new.rb @@ -0,0 +1,25 @@ +# frozen_string_literal: true + +module QA + module Page + module Organization + class New < QA::Page::Base + include QA::Page::Component::Dropdown + view 'app/assets/javascripts/organizations/shared/components/new_edit_form.vue' do + element 'organization-name' + element 'submit-button' + end + + # Sets the organization name + # @param name [string] name of organization + def organization_name=(name) + fill_element('organization-name', name) + end + + def create_organization + click_element('submit-button') + end + end + end + end +end diff --git a/qa/qa/page/organization/show.rb b/qa/qa/page/organization/show.rb new file mode 100644 index 00000000000..402d481bd0a --- /dev/null +++ b/qa/qa/page/organization/show.rb @@ -0,0 +1,18 @@ +# frozen_string_literal: true + +module QA + module Page + module Organization + class Show < QA::Page::Base + include QA::Page::Component::Dropdown + view 'app/assets/javascripts/organizations/show/components/organization_avatar.vue' do + element 'organization-name' + end + + def has_organization?(name) + has_element?('organization-name', text: name) + end + end + end + end +end |