MCPcopy Create free account
hub / github.com/PyCQA/pyflakes / test_recurses

Method test_recurses

pyflakes/test/test_api.py:136–149  ·  view source on GitHub ↗

If the Python files are hidden deep down in child directories, we will find them.

(self)

Source from the content-addressed store, hash-verified

134 self.assertEqual(list(iterSourceCode([self.tempdir])), [])
135
136 def test_recurses(self):
137 """
138 If the Python files are hidden deep down in child directories, we will
139 find them.
140 """
141 os.mkdir(os.path.join(self.tempdir, 'foo'))
142 apath = self.makeEmptyFile('foo', 'a.py')
143 self.makeEmptyFile('foo', 'a.py~')
144 os.mkdir(os.path.join(self.tempdir, 'bar'))
145 bpath = self.makeEmptyFile('bar', 'b.py')
146 cpath = self.makeEmptyFile('c.py')
147 self.assertEqual(
148 sorted(iterSourceCode([self.tempdir])),
149 sorted([apath, bpath, cpath]))
150
151 def test_shebang(self):
152 """

Callers

nothing calls this directly

Calls 2

makeEmptyFileMethod · 0.95
iterSourceCodeFunction · 0.90

Tested by

no test coverage detected