def take_action(self, args): columns = ["id", "description", "status", "release"] result = api.bugs( args.package, release=args.release, rows_per_page=args.rows_per_page, start_row=args.start_row ) rows = result["rows"] return (columns, [[row[col] for col in columns] for row in rows])
def take_action(self, args): columns = ['id', 'description', 'status', 'release'] result = api.bugs( args.package, release=args.release, rows_per_page=args.rows_per_page, start_row=args.start_row, ) rows = result['rows'] return ( columns, [[row[col] for col in columns] for row in rows], )
def test_bugs(self): """ Test the bugs function from the API. """ ## Let's assume there will always be at least one bug against ## guake. guake_bugs = bugs(PKG, release='all') self.assertTrue(len(guake_bugs) > 0)