def get_apis(tags=None, page=None): if tags: apis = CRUD.getApis(tags=tags) else: if page: apis = CRUD.getApis(page=page) else: apis = CRUD.getApis(page=1) j = apis_schema.dump(apis) return j
def test_filter_apis_by_tags(mock_crud, context_api): print('\n=> Testing filtering apis by tags') apis = CRUD.getApis(context_api.get('tags')) assert apis