'A request for the I{base} child of a L{File} succeeds with a resource
for the I{base<extension>} file in the path the L{File} was created
with if such a file exists and the L{File} has been configured to
ignore the I{<extension>} extension.'

def test_ignoredExtensionsIgnored(self):

    base = FilePath(self.mktemp())
    base.makedirs()
    base.child('foo.bar').setContent('baz')
    base.child('foo.quux').setContent('foobar')
    file = static.File(base.path, ignoredExts=('.bar',))
    request = DummyRequest(['foo'])
    child = resource.getChildForRequest(file, request)
    d = self._render(child, request)
    def cbRendered(ignored):
        self.assertEqual(''.join(request.written), 'baz')
    d.addCallback(cbRendered)
    return d
