def test_pkginfo_from_file_exc_and_handler(self):
        from cheeseprism.index import IndexManager
        exc = Exception("BOOM")
        with patch('pkginfo.bdist.BDist', side_effect=exc):
            eh = Mock(name='error_handler')
            IndexManager.pkginfo_from_file('bad.egg', handle_error=eh)
        assert eh.called
        assert eh.call_args[0] == (exc, 'bad.egg'), eh.call_args[0]
.pkginfo_from_file with exception and handler
dataset/ETHPy150Open SMFOSS/CheesePrism/tests/test_index.py/ClassOrStaticMethods.test_pkginfo_from_file_exc_and_handler