Ah I see your point, I am still concerned that the `onVisit` could be called before `onPageChanged` causing a false positive even if it is called afterwards.

How about opening the fail pages with a valid favicon first then reload it with an invalid one, does that fire onPageChanged with `aWhat === Ci.nsINavHistoryObserver.ATTRIBUTE_FAVICON` twice? if so then running the tests on the second event should work.