def test_openForWritingInNotExistingDirectory(self):
        """
        openForWring should fail with a L{ftp.FileNotFoundError} if you specify
        a file in a directory that doesn't exist.
        """
        self.createDirectory('ned')
        d = self.shell.openForWriting(('ned', 'idonotexist', 'foo'))
        return self.assertFailure(d, ftp.FileNotFoundError)

        openForWring should fail with a L{ftp.FileNotFoundError} if you specify
        a file in a directory that doesn't exist.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/test/test_ftp.py