Add sorting to querystring parameters for consistent tests.

Review Request #11662 — Created June 19, 2021 and submitted

Information

RBTools
master

Reviewers

Python 2.x and 3.x iterate dicts in different orders, which has
implications for assembling query strings. We have several tests which
spy on urlopen and return fake payloads, which were failing when run
on Python 3.

This change adds sorting to the querystring parameters before we
assemble them into a URL, and fixes up the test URLs to use those.

Ran unit tests on Python 2.7 and 3.9.

Summary ID
Add sorting to querystring parameters for consistent tests.
Python 2.x and 3.x iterate dicts in different orders, which has implications for assembling query strings. We have several tests which spy on `urlopen` and return fake payloads, which were failing when run on Python 3. This change adds sorting to the querystring parameters before we assemble them into a URL, and fixes up the test URLs to use those. Testing Done: Ran unit tests or Python 2.7 and 3.9.
2f11787d55976e6dfe325874574a6a51524e4122
Description From Last Updated

E501 line too long (118 > 79 characters)

reviewbotreviewbot
Checks run (1 failed, 1 succeeded)
flake8 failed.
JSHint passed.

flake8

david
david
chipx86
  1. Ship It!
  2. 
      
david
Review request changed
Status:
Completed
Change Summary:
Pushed to master (96f1fde)