From 3d76cbd124500f0b5e6ee6a14dfe22189bbd7d4e Mon Sep 17 00:00:00 2001 From: IsaDC <70024509+IsaDC@users.noreply.github.com> Date: Tue, 4 Jun 2024 17:00:38 -0600 Subject: [PATCH] Update Bump into the top edge of a Nested modal dialog Test (#1077) * Modify Bump into the top edge of a Nested modal dialog test for more accurate navigation * Update setupScript * Correct Screen reader commands for test * Update setupScritp --- tests/modal-dialog/data/jaws-commands.csv | 2 +- ...sAddedDialogAndFocusAddressAddedHeading.js | 4 + tests/modal-dialog/data/nvda-commands.csv | 2 +- tests/modal-dialog/data/scripts.csv | 1 + tests/modal-dialog/data/tests.csv | 2 +- .../data/voiceover_macos-commands.csv | 2 +- .../reference/2022-4-7_15544/dialog.html | 2 +- ...g.moveFocusToAddDeliveryAddressButton.html | 2 +- ...eliveryAddressDialogAndFocusAddButton.html | 2 +- ...veryAddressDialogAndFocusCancelButton.html | 2 +- ...liveryAddressDialogAndFocusFirstInput.html | 2 +- ...ddedDialogAndFocusAddressAddedHeading.html | 195 ++++++++++++++++++ ...essAddedDialogAndFocusYourProfileLink.html | 2 +- ...cationResultDialogAndFocusCloseButton.html | 2 +- 14 files changed, 211 insertions(+), 11 deletions(-) create mode 100644 tests/modal-dialog/data/js/openAddressAddedDialogAndFocusAddressAddedHeading.js create mode 100644 tests/modal-dialog/reference/2022-4-7_15544/dialog.openAddressAddedDialogAndFocusAddressAddedHeading.html diff --git a/tests/modal-dialog/data/jaws-commands.csv b/tests/modal-dialog/data/jaws-commands.csv index d353b5e81..500605dc8 100644 --- a/tests/modal-dialog/data/jaws-commands.csv +++ b/tests/modal-dialog/data/jaws-commands.csv @@ -25,5 +25,5 @@ closeNestedModalDialog,space,virtualCursor,,24.1 closeNestedModalDialog,enter,virtualCursor,,24.2 closeNestedModalDialog,space,pcCursor,,24.3 closeNestedModalDialog,enter,pcCursor,,24.4 -bumpTopEdgeOfNestedModal,ctrl+home up up ins+up,virtualCursor,,30 +bumpTopEdgeOfNestedModal,up up ins+up,virtualCursor,,30 bumpBottomEdgeOfNestedModal,ctrl+end down down ins+up,virtualCursor,,31 diff --git a/tests/modal-dialog/data/js/openAddressAddedDialogAndFocusAddressAddedHeading.js b/tests/modal-dialog/data/js/openAddressAddedDialogAndFocusAddressAddedHeading.js new file mode 100644 index 000000000..c8a5c4b19 --- /dev/null +++ b/tests/modal-dialog/data/js/openAddressAddedDialogAndFocusAddressAddedHeading.js @@ -0,0 +1,4 @@ +// opens the 'Add Delivery Address' dialog followed by the 'Address Added' dialog, and sets focus on the 'Address added' heading inside the second dialog +const btn = testPageDocument.querySelector('#ex1 > button'); +testPageDocument.defaultView.openDialog('dialog1', btn, 'dialog1_add'); +testPageDocument.defaultView.replaceDialog('dialog3', undefined, 'dialog3_label'); diff --git a/tests/modal-dialog/data/nvda-commands.csv b/tests/modal-dialog/data/nvda-commands.csv index ad369367e..aeb3207d5 100644 --- a/tests/modal-dialog/data/nvda-commands.csv +++ b/tests/modal-dialog/data/nvda-commands.csv @@ -25,5 +25,5 @@ closeNestedModalDialog,space,browseMode,,24.1 closeNestedModalDialog,enter,browseMode,,24.2 closeNestedModalDialog,space,focusMode,,24.3 closeNestedModalDialog,enter,focusMode,,24.4 -bumpTopEdgeOfNestedModal,ctrl+home up up ins+up,browseMode,,30 +bumpTopEdgeOfNestedModal,up up ins+up,browseMode,,30 bumpBottomEdgeOfNestedModal,ctrl+end down down ins+up,browseMode,,31 diff --git a/tests/modal-dialog/data/scripts.csv b/tests/modal-dialog/data/scripts.csv index ebfa62da0..d8a8d8a0c 100644 --- a/tests/modal-dialog/data/scripts.csv +++ b/tests/modal-dialog/data/scripts.csv @@ -5,3 +5,4 @@ openAddDeliveryAddressDialogAndFocusCancelButton,"opens the 'Add Delivery Addres openAddDeliveryAddressDialogAndFocusFirstInput,"opens the 'Add Delivery Address' modal dialog, and sets focus on the first input" openAddressAddedDialogAndFocusYourProfileLink,"opens the 'Add Delivery Address' dialog followed by the 'Address Added' dialog, and sets focus on the 'your profile' link inside the second dialog" openVerificationResultDialogAndFocusCloseButton,"opens the 'Add Delivery Address' dialog followed by the 'Verification Result' dialog, and sets focus on the 'Close' button inside the second dialog" +openAddressAddedDialogAndFocusAddressAddedHeading,"opens the 'Add Delivery Address' dialog followed by the 'Address Added' dialog, and sets focus on the 'Address added' heading inside the second dialog" diff --git a/tests/modal-dialog/data/tests.csv b/tests/modal-dialog/data/tests.csv index 151805eca..138006c36 100644 --- a/tests/modal-dialog/data/tests.csv +++ b/tests/modal-dialog/data/tests.csv @@ -9,5 +9,5 @@ bumpTopEdge,Bump into the top edge of a modal dialog,16,openAddDeliveryAddressDi bumpBottomEdge,Bump into the bottom edge of a modal dialog,16.1,openAddDeliveryAddressDialogAndFocusAddButton,"Starting at the 'Add' button inside the dialog, navigate to the bottom of the dialog and make multiple attempts to navigate past the bottom edge.",cursorAtCancelButton openNestedModalDialog,Open a nested modal dialog ,20,openAddDeliveryAddressDialogAndFocusAddButton,"Starting at the 'Add' button inside the dialog, activate it to open the nested 'Address Added' dialog.",roleDialog nameAddressAdded dialogDescriptionAsTheAddressYouProvidedHasBeenAddedToYourListDeliveryAddressesItIsReadyForImmediateUseIfYouWishToRemoveItYouCanDoSoFromYourProfile roleFocusedElementButton nameFocusedElementOk closeNestedModalDialog,Close a nested modal dialog,30,openVerificationResultDialogAndFocusCloseButton,"Starting at the 'Close' button inside the nested dialog, close the dialog.",roleDialog nameAddDeliveryAddress roleButton nameVerifyAddress -bumpTopEdgeOfNestedModal,Bump into the top edge of a Nested modal dialog,40,openAddressAddedDialogAndFocusYourProfileLink,"Starting at the 'Your Profile' link inside the nested dialog, navigate to the top of the dialog and make multiple attempts to navigate past the top edge.",cursorAtAddressAddedHeading +bumpTopEdgeOfNestedModal,Bump into the top edge of a Nested modal dialog,40,openAddressAddedDialogAndFocusAddressAddedHeading,"Starting at the 'Address Added' heading inside the nested dialog, navigate to the top of the dialog and make multiple attempts to navigate past the top edge.",cursorAtAddressAddedHeading bumpBottomEdgeOfNestedModal,Bump into the bottom edge of a Nested modal dialog,40.1,openAddressAddedDialogAndFocusYourProfileLink,"Starting at the 'Your Profile' link inside the nested dialog, navigate to the bottom of the dialog and make multiple attempts to navigate past the bottom edge.",cursorAtOKButton diff --git a/tests/modal-dialog/data/voiceover_macos-commands.csv b/tests/modal-dialog/data/voiceover_macos-commands.csv index f0ebd6b2c..003cac57b 100644 --- a/tests/modal-dialog/data/voiceover_macos-commands.csv +++ b/tests/modal-dialog/data/voiceover_macos-commands.csv @@ -19,5 +19,5 @@ closeNestedModalDialog,esc,,,23 closeNestedModalDialog,ctrl+opt+space,,,23.1 closeNestedModalDialog,space,,,23.2 closeNestedModalDialog,enter,,,23.3 -bumpTopEdgeOfNestedModal,ctrl+opt+home ctrl+opt+left ctrl+opt+left ctrl+opt+f3,,,30 +bumpTopEdgeOfNestedModal,ctrl+opt+left ctrl+opt+left ctrl+opt+f3,,,30 bumpBottomEdgeOfNestedModal,ctrl+opt+end ctrl+opt+right ctrl+opt+right ctrl+opt+f3,,,31 diff --git a/tests/modal-dialog/reference/2022-4-7_15544/dialog.html b/tests/modal-dialog/reference/2022-4-7_15544/dialog.html index f714d8edc..abef188e2 100644 --- a/tests/modal-dialog/reference/2022-4-7_15544/dialog.html +++ b/tests/modal-dialog/reference/2022-4-7_15544/dialog.html @@ -137,7 +137,7 @@

Verification Result