'Test that getCache skips over any entries in a plugin package\'s
C{__path__} which do not exist.'

def test_nonexistentPathEntry(self):

    path = self.mktemp()
    self.assertFalse(os.path.exists(path))
    self.module.__path__.append(path)
    try:
        plgs = list(plugin.getPlugins(ITestPlugin, self.module))
        self.assertEqual(len(plgs), 1)
    finally:
        self.module.__path__.remove(path)
