Skip to content
This repository has been archived by the owner on Apr 7, 2022. It is now read-only.

[1LP][RFR] Automating dynamic refresh dialog test #10052

Merged
merged 1 commit into from
Apr 22, 2020

Conversation

niyazRedhat
Copy link
Contributor

@niyazRedhat niyazRedhat commented Apr 14, 2020

Purpose or Intent

PRT Run

{{pytest: cfme/tests/services/test_dynamicdd_dialogelement.py::test_dynamic_field_update_on_refresh -vvvv --long-running }}

  • test_regex_validation_should_work this is also covered in this PR
  • removed test_reconfigure_service_for_dialogs_with_timeout_values, we already have automation -> test_reconfigure_service
  • removed few nonrequired tests which no need to test.
  • remove test_should_be_able_to_see_requests_if_our_users..., we already have related test test_service_rbac_request

@niyazRedhat niyazRedhat changed the title [WIPTEST] Automating dynamic refresh dialog test [RFR] Automating dynamic refresh dialog test Apr 14, 2020
@niyazRedhat niyazRedhat force-pushed the dyn_dialog branch 2 times, most recently from 318b724 to f5e6764 Compare April 14, 2020 09:37
@niyazRedhat niyazRedhat force-pushed the dyn_dialog branch 3 times, most recently from 69cb46e to 1df36e1 Compare April 14, 2020 10:08
@john-dupuy john-dupuy added the test-automation To be applied on PR's which are automating existing manual cases label Apr 15, 2020
Comment on lines 499 to 509
menu = view.fields("menu").read()
topping = view.fields("dropdown_list_1").read()

if menu == 'Burger':
assert topping == 'Black Bean'
elif menu == "Fries":
assert topping == "Sweet Potato"
elif menu == 'Shake':
assert topping == 'Vanilla'
elif menu == 'Empty Set':
assert topping == 'Nothing selected for parent dialog'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How is the value selected for menu? Is it random or does it stay the same always?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@valaparthvi It randomly select the value when we refresh the field view.fields("Menu").refresh.click()

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Optional

Suggested change
menu = view.fields("menu").read()
topping = view.fields("dropdown_list_1").read()
if menu == 'Burger':
assert topping == 'Black Bean'
elif menu == "Fries":
assert topping == "Sweet Potato"
elif menu == 'Shake':
assert topping == 'Vanilla'
elif menu == 'Empty Set':
assert topping == 'Nothing selected for parent dialog'
data = {"Burger": "Black Bean", "Fries": "Sweet Potato", "Shake": "Vanilla", "Empty Set": "Nothing selected for parent dialog"}
assert topping == data[menu]

@valaparthvi valaparthvi added the test-cleanup Test removal, collection changes, re-organization label Apr 22, 2020
Copy link
Contributor

@valaparthvi valaparthvi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Comment on lines 499 to 509
menu = view.fields("menu").read()
topping = view.fields("dropdown_list_1").read()

if menu == 'Burger':
assert topping == 'Black Bean'
elif menu == "Fries":
assert topping == "Sweet Potato"
elif menu == 'Shake':
assert topping == 'Vanilla'
elif menu == 'Empty Set':
assert topping == 'Nothing selected for parent dialog'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Optional

Suggested change
menu = view.fields("menu").read()
topping = view.fields("dropdown_list_1").read()
if menu == 'Burger':
assert topping == 'Black Bean'
elif menu == "Fries":
assert topping == "Sweet Potato"
elif menu == 'Shake':
assert topping == 'Vanilla'
elif menu == 'Empty Set':
assert topping == 'Nothing selected for parent dialog'
data = {"Burger": "Black Bean", "Fries": "Sweet Potato", "Shake": "Vanilla", "Empty Set": "Nothing selected for parent dialog"}
assert topping == data[menu]

@valaparthvi valaparthvi changed the title [RFR] Automating dynamic refresh dialog test [1LP][RFR] Automating dynamic refresh dialog test Apr 22, 2020
@mshriver mshriver merged commit ed56002 into ManageIQ:master Apr 22, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lint-ok test-automation To be applied on PR's which are automating existing manual cases test-cleanup Test removal, collection changes, re-organization
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants