def test_directory(self):
        """
        L{filenameToModuleName} returns the correct module (a package) given a
        directory.
        """
        module = reflect.filenameToModuleName(self.path)
        self.assertEqual(module, 'fakepackage.test')
        module = reflect.filenameToModuleName(self.path + os.path.sep)
        self.assertEqual(module, 'fakepackage.test')

        L{filenameToModuleName} returns the correct module (a package) given a
        directory.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/test/test_reflect.py