One of the tests I wrote, if all fields are empty, was still rendering divs in an empty <></>. I added a second condition to the formatAddress function that checks whether all the text in address is null, in which case it should return empty, similar to if no address is provided.
Checklist
[ ] If this code affects the other scrum team, have they been notified? (In Slack, as reviewers, etc.)
PULL REQUEST
Summary
This adds unit tests for formatAddress.
Related Issue
Fixes #1991
Additional Information
One of the tests I wrote, if all fields are empty, was still rendering
div
s in an empty <></>. I added a second condition to theformatAddress
function that checks whether all the text inaddress
is null, in which case it should return empty, similar to if no address is provided.Checklist