Fix JSONP callbacks for errored responses on Android

Android 2.3 doesn't call the `onerror` handlers for HTTP 500 responses
like it does for 404s. However, it does trigger the `onload` handler.

This rewrites the JSONP implementation to use a combination of `onload`
and `onerror` handlers to invoke the standard Ajax callbacks. If the
JSON data was never received, this always treats it as an error even if
it executed through `onload`.

References #871
Silence test warnings about unexpected JSONP globals

The test runner is set up to display warnings about leaked global
variables. Since we expect to have artefacts of JSONP requests in form
of keys named "jsonpXY" on the window object, this explicitly cleans
them up so they are ignored.
Add an "Expires" header to Ajax caching test

Unfortunately it doesn't fix the Android 2.3 intermittent failure.
Sometimes it will reuse cached response, sometimes it will refetch.