Closed Bug 1844158 Opened 2 years ago Closed 1 year ago

Switch ShoppingProduct tests to use processAsync methods on the http server

Categories

(Firefox Graveyard :: Shopping, task, P3)

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: fchasen, Unassigned)

References

Details

(Whiteboard: [fidefe-shopping])

Currently we use a simple sync readFile method to get the responses, but can pass an async function to registerPathHandler instead and use a regular fetch call.

Gijs mention that if we switch we can also properly test the abort controller:

With the processAsync methods on the http server you can effectively block the response until you flip a switch on the outside of the http handler. You could use that to ensure that if there's no response before we call the abort controller, the request is actually aborted (whereas this checks the signal but doesn't check that the fetch request actually gets aborted).

Whiteboard: [fidefe-shopping]
Severity: -- → S3
Priority: -- → P1
Assignee: fchasen → nobody
Status: ASSIGNED → NEW

This bug is being closed because we are closing the Bugzilla component.
If this still needs attention, please re-open and change component to
the appropriate component or "General".

Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → INCOMPLETE
Product: Firefox → Firefox Graveyard
You need to log in before you can comment on or make changes to this bug.