/functional_tests/test_entrypoints.py
Python | 17 lines | 13 code | 4 blank | 0 comment | 0 complexity | 6c5fc39e6345b69274171399eacb8175 MD5 | raw file
1import os 2import sys 3from nose.exc import SkipTest 4 5try: 6 from pkg_resources import EntryPoint 7except ImportError: 8 raise SkipTest("No setuptools available; skipping") 9 10here = os.path.dirname(__file__) 11support = os.path.join(here, 'support') 12ep = os.path.join(support, 'ep') 13 14 15def test_plugin_entrypoint_is_loadable(): 16 epfile = os.path.join(ep, 'Some_plugin.egg-info', 'entry_points.txt') 17 assert EntryPoint.parse_map(open(epfile, 'r').readlines())