Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

Commit

Permalink
fix test for init files to exclude mturk html dir (#203)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexholdenmiller authored Jul 12, 2017
1 parent 9d3b8f8 commit b7faaaa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,16 @@


class TestInit(unittest.TestCase):
"""Make sure the package is alive."""
"""Make sure all python packages have init files."""

def test_init_everywhere(self):
from parlai.core.params import ParlaiParser
opt = ParlaiParser().parse_args()
for root, subfolder, files in os.walk(os.path.join(opt['parlai_home'], 'parlai')):
if not root.endswith('__pycache__'):
if os.path.basename(root) == 'html':
# skip mturk core's html folder--not a python module
continue
assert '__init__.py' in files, 'Dir {} is missing __init__.py'.format(root)


Expand Down

0 comments on commit b7faaaa

Please sign in to comment.