#NEWLINE# @ mock . patch . object ( cfg . ConfigOpts , 'find_file' ) #NEWLINE# @ mock . patch . object ( utils , 'read_cached_file' ) #NEWLINE# def test_filemanager_returned( self , mock_read_cached_file , mock_find_file ) : #NEWLINE# #INDENT# mock_find_file . return_value = '/etc/nova/cells.json' #NEWLINE# mock_read_cached_file . return_value = ( False , six . StringIO ( '{}' ) ) #NEWLINE# self . flags ( cells_config = 'cells.json' , group = 'cells' ) #NEWLINE# manager = state . CellStateManager ( ) #NEWLINE# self . assertIsInstance ( manager , state . CellStateManagerFile ) #NEWLINE# self . assertRaises ( exception . CellsUpdateUnsupported , manager . cell_create , None , None ) #NEWLINE# self . assertRaises ( exception . CellsUpdateUnsupported , manager . cell_update , None , None , None ) #NEWLINE# self . assertRaises ( exception . CellsUpdateUnsupported , manager . cell_delete , None , None )