Use all-caps GIVEN/WHEN/THEN in MetricsUtilsTestRobolectric test names
Categories
(Firefox for Android :: General, task)
Tracking
()
People
(Reporter: skhan, Unassigned, Mentored)
Details
(Keywords: good-first-bug, Whiteboard: [lang=kotlin])
Filing as a good first bug to learn workflows.
All 18 test names in MetricsUtilsTestRobolectric.kt spell the Given/When/Then parts in lower case, which makes the three parts of each name hard to pick out when scanning the file. Much of the tree writes them in capitals instead. The task is to rewrite the names in that file so GIVEN, WHEN and THEN are capitalised, changing nothing else.
For example:
fun `given a search engine with a telemetry suffix, when recording a search then the telemetry id is the engine id with the suffix`()
would become:
fun `GIVEN a search engine with a telemetry suffix WHEN recording a search THEN the telemetry id is the engine id with the suffix`()
Only the names change. Do not change what any test does, and do not rename the file or the class. A few names do not have all three parts, and those keep whatever parts they have.
To verify the fix, the same 18 tests should still be there and still pass:
./mach gradle -p mobile/android/fenix app:testDebugUnitTest --tests 'MetricsUtilsTestRobolectric'
This was asked for as a follow-up while reviewing D337309, so the file reads consistently with the convention used elsewhere in the tree.
Tutorial to contribute:
https://firefox-source-docs.mozilla.org/contributing/contribution_quickref.html
https://firefox-source-docs.mozilla.org/contributing/stack_quickref.html
Please don't ask for the bug to be assigned. It will be automatically assigned to the first patch.
Description
•