ServiceWorker: Deflake postmessage.html

postmessage.html sometimes fails due to an assertion failure.

Before this patch, the test expected to receive 'statechange' event for
'redundant' shortly after unregister() but it could be for 'activated'.
After this patch, the test correctly waits for 'redundant'.


BUG=n/a
TEST=run_webkit_tests.py --debug http/tests/serviceworker/postmessage.html

Review URL: https://codereview.chromium.org/584513002

git-svn-id: svn://svn.chromium.org/blink/trunk@182299 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Remove unregister() from ServiceWorkerContainer

BUG=404064

Review URL: https://codereview.chromium.org/581293002

git-svn-id: svn://svn.chromium.org/blink/trunk@182300 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Use getRegistration in service_worker_unregister_and_register

Now it can be used with a worker that doesn't install successfully.

BUG=404064

Review URL: https://codereview.chromium.org/587573002

git-svn-id: svn://svn.chromium.org/blink/trunk@182301 bbb929c8-8fbe-4397-9dbb-9b2b20218538