def _404Test(self, name):
        """
        Verify that requesting the C{name} child of C{self.directory} results
        in a 404 response.
        """
        request = DummyRequest([name])
        result = self.directory.getChild(name, request)
        d = _render(result, request)
        def cbRendered(ignored):
            self.assertEqual(request.responseCode, 404)
        d.addCallback(cbRendered)
        return d

        Verify that requesting the C{name} child of C{self.directory} results
        in a 404 response.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/web/test/test_distrib.py