def test_channels_listall_joined(): assert (channels_list_all(hamish['token']) == [ { 'channel_id': channel_id_hamish['channel_id'], 'name': 'Hamish_channel' }, { 'channel_id': channel_id_zach['channel_id'], 'name': 'Zach_channel' }, { 'channel_id': channel_id_kelly['channel_id'], 'name': 'Kelly_channel' }, ])
def c_listall(): """ This is a flask wrapper for the channels_list_all function Parameters: No parameters Returns: (dictionary): A dictionary which contains the key called channels and is a list of channels and their associated details """ token = request.args.get('token') if not token_check(token): raise AccessError(description="Invalid token") return_dict = channels_list_all(token) return dumps(return_dict)
def c_listall(): token = request.args.get('token') return_dict = channels_list_all(token) print(return_dict) return dumps(return_dict)