'The realm value included in the I{WWW-Authenticate} header set in
the response when L{UnauthorizedResounrce} is rendered has quotes
and backslashes escaped.'

def test_renderQuotesRealm(self):

    resource = UnauthorizedResource([BasicCredentialFactory('example\\"foo')])
    request = DummyRequest([''])
    request.render(resource)
    self.assertEqual(request.responseHeaders.getRawHeaders('www-authenticate'), ['basic    realm="example\\\\\\"foo"'])
