@pytest.mark.xfail('not HAS_BZ2')
def test_guessing_file_object():
 t = ascii.read(open('t/ipac.dat.bz2', 'rb'))
 assert (t.colnames == ['ra', 'dec', 'sai', 'v2', 'sptype'])

@ pytest . mark . xfail ( 'not HAS_BZ2' ) def test_guessing_file_object ( ) : t = ascii . read ( open ( 't/ipac.dat.bz2' , 'rb' ) ) assert ( t . colnames == [ 'ra' , 'dec' , 'sai' , 'v2' , 'sptype' ] )
test guessing a file object .