':param custom_routes: the additional routes can be added by this
parameter. This parameter is used to test on some fake routes
primarily.'

def __init__(self, custom_routes=None):

    super(APIRouterV21, self).__init__(nova.api.openstack.ProjectMapper())
    if (custom_routes is None):
        custom_routes = tuple()
    for (path, methods) in (ROUTE_LIST + custom_routes):
        if isinstance(methods, str):
            self.map.redirect(path, methods)
            continue
        for (method, controller_info) in methods.items():
            controller = controller_info[0]()
            action = controller_info[1]
            self.map.create_route(path, method, controller, action)
