#NEWLINE# def test_table_tabs( self ) : #NEWLINE# #INDENT# tab_group = TableTabGroup ( self . request ) #NEWLINE# tabs = tab_group . get_tabs ( ) #NEWLINE# self . assertEqual ( 1 , len ( tabs ) ) #NEWLINE# tab = tabs [ 0 ] #NEWLINE# self . assertIsInstance ( tab , horizon_tabs . TableTab ) #NEWLINE# self . assertFalse ( tabs . _table_data_loaded ) #NEWLINE# table = tab . _tables [ MyTable . Meta . name ] #NEWLINE# self . assertIsInstance ( table , MyTable ) #NEWLINE# self . assertIsNone ( table . data ) #NEWLINE# tab . load_table_data ( ) #NEWLINE# self . assertTrue ( tab . _table_data_loaded ) #NEWLINE# self . assertQuerysetEqual ( table . data , [ '<FakeObject: object_1>' , '<FakeObject: object_2>' , '<FakeObject: object_3>' ] ) #NEWLINE# context = tab . get_context_data ( self . request ) #NEWLINE# self . assertEqual ( table , context [ 'my_table_table' ] ) #NEWLINE# self . assertEqual ( table , context [ 'table' ] )