Cmcmahon has uploaded a new change for review.
https://gerrit.wikimedia.org/r/74182
Change subject: Update VE tests for current behavior, verified no bugs
......................................................................
Update VE tests for current behavior, verified no bugs
Change-Id: I401c95026d45a30599f4fe4d864eda79a11c000c
---
M features/step_definitions/visual_editor_references_steps.rb
M features/step_definitions/visual_editor_transclusion_steps.rb
M features/support/pages/visual_editor_page.rb
M features/visual_editor_references.feature
M features/visual_editor_transclusion.feature
5 files changed, 17 insertions(+), 7 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/qa/browsertests
refs/changes/82/74182/1
diff --git a/features/step_definitions/visual_editor_references_steps.rb
b/features/step_definitions/visual_editor_references_steps.rb
index 061878d..8d980f2 100644
--- a/features/step_definitions/visual_editor_references_steps.rb
+++ b/features/step_definitions/visual_editor_references_steps.rb
@@ -23,3 +23,9 @@
Then(/^I should see Insert reference button enabled$/) do
on(VisualEditorPage).insert_reference_element.should be_visible
end
+
+Then(/^I should see the second Apply changes button$/) do
+ sleep 2
+ on(VisualEditorPage).apply_changes_new_frame_element.should be_visible
+end
+
diff --git a/features/step_definitions/visual_editor_transclusion_steps.rb
b/features/step_definitions/visual_editor_transclusion_steps.rb
index e80ec93..6ac18bb 100644
--- a/features/step_definitions/visual_editor_transclusion_steps.rb
+++ b/features/step_definitions/visual_editor_transclusion_steps.rb
@@ -5,7 +5,7 @@
Given(/^I have added a parameter to a template$/) do
step 'I have added a template'
step 'I enter x in the parameter box'
- step 'I click Add parameter'
+ step 'I add the parameter'
end
Given(/^I have added a template$/) do
@@ -14,7 +14,7 @@
on(VisualEditorPage).add_template_element.when_present.click
end
-When(/^I click Add parameter$/) do
+When(/^I add the parameter$/) do
on(VisualEditorPage).add_parameter_element.when_present.click
end
@@ -39,7 +39,7 @@
end
Then(/^I should see a list of template suggestions$/) do
- on(VisualEditorPage).suggestion_list_element.should be_visible
+ on(VisualEditorPage).suggestion_list_element.when_present.should be_visible
end
Then(/^I should be able to click the Add template button$/) do
@@ -54,5 +54,5 @@
end
Then(/^I should see the Apply changes button$/) do
- on(VisualEditorPage).apply_changes_element.should be_visible
+ on(VisualEditorPage).apply_changes_element.when_present.should be_visible
end
\ No newline at end of file
diff --git a/features/support/pages/visual_editor_page.rb
b/features/support/pages/visual_editor_page.rb
index 8c63997..d07a006 100644
--- a/features/support/pages/visual_editor_page.rb
+++ b/features/support/pages/visual_editor_page.rb
@@ -23,7 +23,7 @@
span(:transclusion, class: 've-ui-buttonTool-icon ve-ui-icon-template')
in_frame(:index => 0) do |frame|
- span(:add_parameter, text: 'Add parameter', frame: frame)
+ span(:add_parameter, class: 've-ui-mwParameterResultWidget-name', frame:
frame)
span(:add_template, text: 'Add template', frame: frame)
span(:apply_changes, text: 'Apply changes', frame: frame)
text_field(:content_box, index: 0, frame: frame)
@@ -41,4 +41,8 @@
div(:title, class: 've-ui-window-title', frame: frame)
text_area(:transclusion_textarea, index: 0, frame: frame)
end
+
+ in_frame(:index => 1) do |frame|
+ span(:apply_changes_new_frame, text: 'Apply changes', frame: frame)
+ end
end
diff --git a/features/visual_editor_references.feature
b/features/visual_editor_references.feature
index 18dce56..1eeaf2e 100644
--- a/features/visual_editor_references.feature
+++ b/features/visual_editor_references.feature
@@ -11,4 +11,4 @@
Given I can see the References User Interface
When I enter THIS IS CONTENT into Content box
And I click Create new source
- Then I should see Insert reference button enabled
+ Then I should see the second Apply changes button
diff --git a/features/visual_editor_transclusion.feature
b/features/visual_editor_transclusion.feature
index 88914ac..483fa05 100644
--- a/features/visual_editor_transclusion.feature
+++ b/features/visual_editor_transclusion.feature
@@ -16,7 +16,7 @@
Scenario: Add parameter to template
Given I have added a template
When I enter x in the parameter box
- And I click Add parameter
+ And I add the parameter
Then I should see an input text area
And I should see the Apply changes button
--
To view, visit https://gerrit.wikimedia.org/r/74182
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I401c95026d45a30599f4fe4d864eda79a11c000c
Gerrit-PatchSet: 1
Gerrit-Project: qa/browsertests
Gerrit-Branch: master
Gerrit-Owner: Cmcmahon <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits