PageFormCompleter: Improved detecting sent form.

Also added new test.