Fixed #18924 -- Made test.Client.logout send user_logged_out signal.

Patch for [#18924](https://code.djangoproject.com/ticket/18924)

Updated Pavel Ponomarev's patch (pull request #322) to work with custom user models