s/QtCore.Qt.escape/cgi.escape/g

The former does not exist on my system.
Fix tests that broke after 099146a