Skip to content

fix types returned by update and create role bindings #27

@rob-baron

Description

@rob-baron

Fix the types returned by update and create role bindings as they return more than Response.

When setting abstract function instead of specifying them as:

    class MocOpenShift(metaclass=abc.ABCMeta):
        @abc.abstractmethod -> Response
        def create_rolebindings(self, project_name, user_name, role)->Response:
            return Response()

        @abc.abstractmethod -> Response
        def update_rolebindings(self, project_name, role, rolebindings_json)->Response:
            return Response()

Had to use:

    class MocOpenShift(metaclass=abc.ABCMeta):
        @abc.abstractmethod
        def create_rolebindings(self, project_name, user_name, role):
            return 

        @abc.abstractmethod
        def update_rolebindings(self, project_name, role, rolebindings_json):
            return

Will also fix (#10)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions