Switch all cases of window.location over to RB.navigateTo.

Review Request #12736 — Created Nov. 22, 2022 and submitted

Information

Review Board
release-6.x

Reviewers

The new navigateTo method allows us to spy on things that would cause
the page to reload or navigate away during the test suite. We have a
couple cases of similar methods that were just part of other objects,
and a bunch of cases where we were assigning directly to
window.location. This change switches everything over to the new one.

Ran js-tests.

Summary ID
Switch all cases of window.location over to RB.navigateTo.
The new `navigateTo` method allows us to spy on things that would cause the page to reload or navigate away during the test suite. We have a couple cases of similar methods that were just part of other objects, and a bunch of cases where we were assigning directly to `window.location`. This change switches everything over to the new one. Testing Done: Ran js-tests.
235e17eca9857e632cc9e717456711f91bc7aa52
Description From Last Updated

Worth noting for here and other replace() usage: replace() will replace the history entry, whereas navigateTo() will append a history …

chipx86chipx86

boolean in JavaScript.

chipx86chipx86
chipx86
  1. 
      
  2. Show all issues

    Worth noting for here and other replace() usage: replace() will replace the history entry, whereas navigateTo() will append a history entry. Matters for the Back button, and what we want for switching tabs/views in the review UIs.

    I'd suggest we augment navigateTo() to take options and pass in a replace: true for these.

  3. 
      
david
maubin
  1. Ship It!
  2. 
      
chipx86
  1. Awesome, thank you for doing this!

  2. Show all issues

    boolean in JavaScript.

  3. 
      
david
Review request changed
Status:
Completed
Change Summary:
Pushed to release-6.x (7c5010b)