'Test the lookup_future_symbol method.'

def test_lookup_future_symbol(self):

    om = TestFuture.asset_finder.lookup_future_symbol('OMH15')
    self.assertEqual(om.sid, 2468)
    self.assertEqual(om.symbol, 'OMH15')
    self.assertEqual(om.root_symbol, 'OM')
    self.assertEqual(om.notice_date, pd.Timestamp('2014-01-20', tz='UTC'))
    self.assertEqual(om.expiration_date, pd.Timestamp('2014-02-20', tz='UTC'))
    self.assertEqual(om.auto_close_date, pd.Timestamp('2014-01-18', tz='UTC'))
    cl = TestFuture.asset_finder.lookup_future_symbol('CLG06')
    self.assertEqual(cl.sid, 0)
    self.assertEqual(cl.symbol, 'CLG06')
    self.assertEqual(cl.root_symbol, 'CL')
    self.assertEqual(cl.start_date, pd.Timestamp('2005-12-01', tz='UTC'))
    self.assertEqual(cl.notice_date, pd.Timestamp('2005-12-20', tz='UTC'))
    self.assertEqual(cl.expiration_date, pd.Timestamp('2006-01-20', tz='UTC'))
    with self.assertRaises(SymbolNotFound):
        TestFuture.asset_finder.lookup_future_symbol('')
    with self.assertRaises(SymbolNotFound):
        TestFuture.asset_finder.lookup_future_symbol('#&?!')
    with self.assertRaises(SymbolNotFound):
        TestFuture.asset_finder.lookup_future_symbol('FOOBAR')
    with self.assertRaises(SymbolNotFound):
        TestFuture.asset_finder.lookup_future_symbol('XXX99')
