// Code generated by mockery v1.0.0. DO NOT EDIT.

// Code generated - this lets golint know to skip this file - DO NOT EDIT.

package rolemocks

import beefcake "code.justin.tv/beefcake/server/rpc/beefcake"
import context "context"
import mock "github.com/stretchr/testify/mock"
import role "code.justin.tv/beefcake/server/internal/role"

// RolesAPI is an autogenerated mock type for the RolesAPI type
type RolesAPI struct {
	mock.Mock
}

// AddLegacyPermission provides a mock function with given fields: ctx, roleID, permID
func (_m *RolesAPI) AddLegacyPermission(ctx context.Context, roleID string, permID string) error {
	ret := _m.Called(ctx, roleID, permID)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string) error); ok {
		r0 = rf(ctx, roleID, permID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// AddLegacyPermissionDetails provides a mock function with given fields: ctx, roleID, details
func (_m *RolesAPI) AddLegacyPermissionDetails(ctx context.Context, roleID string, details *beefcake.Permission_LegacyPermission) error {
	ret := _m.Called(ctx, roleID, details)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, *beefcake.Permission_LegacyPermission) error); ok {
		r0 = rf(ctx, roleID, details)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// AddPermission provides a mock function with given fields: ctx, roleID, permission
func (_m *RolesAPI) AddPermission(ctx context.Context, roleID string, permission *beefcake.Permission) error {
	ret := _m.Called(ctx, roleID, permission)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, *beefcake.Permission) error); ok {
		r0 = rf(ctx, roleID, permission)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// AddUserMembership provides a mock function with given fields: ctx, roleID, um
func (_m *RolesAPI) AddUserMembership(ctx context.Context, roleID string, um *beefcake.Role_UserMembership) error {
	ret := _m.Called(ctx, roleID, um)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, *beefcake.Role_UserMembership) error); ok {
		r0 = rf(ctx, roleID, um)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// All provides a mock function with given fields: ctx
func (_m *RolesAPI) All(ctx context.Context) ([]*role.Role, error) {
	ret := _m.Called(ctx)

	var r0 []*role.Role
	if rf, ok := ret.Get(0).(func(context.Context) []*role.Role); ok {
		r0 = rf(ctx)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]*role.Role)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(context.Context) error); ok {
		r1 = rf(ctx)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Create provides a mock function with given fields: ctx, roleName
func (_m *RolesAPI) Create(ctx context.Context, roleName string) (*role.Role, error) {
	ret := _m.Called(ctx, roleName)

	var r0 *role.Role
	if rf, ok := ret.Get(0).(func(context.Context, string) *role.Role); ok {
		r0 = rf(ctx, roleName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*role.Role)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(context.Context, string) error); ok {
		r1 = rf(ctx, roleName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Delete provides a mock function with given fields: ctx, roleID
func (_m *RolesAPI) Delete(ctx context.Context, roleID string) error {
	ret := _m.Called(ctx, roleID)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string) error); ok {
		r0 = rf(ctx, roleID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// Get provides a mock function with given fields: ctx, roleID
func (_m *RolesAPI) Get(ctx context.Context, roleID string) (*role.Role, error) {
	ret := _m.Called(ctx, roleID)

	var r0 *role.Role
	if rf, ok := ret.Get(0).(func(context.Context, string) *role.Role); ok {
		r0 = rf(ctx, roleID)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*role.Role)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(context.Context, string) error); ok {
		r1 = rf(ctx, roleID)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Override provides a mock function with given fields: ctx, roleID, name, permissions, memberships
func (_m *RolesAPI) Override(ctx context.Context, roleID string, name string, permissions []*beefcake.Permission, memberships []*beefcake.Role_UserMembership) error {
	ret := _m.Called(ctx, roleID, name, permissions, memberships)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string, []*beefcake.Permission, []*beefcake.Role_UserMembership) error); ok {
		r0 = rf(ctx, roleID, name, permissions, memberships)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// RemoveLegacyPermission provides a mock function with given fields: ctx, roleID, permID
func (_m *RolesAPI) RemoveLegacyPermission(ctx context.Context, roleID string, permID string) error {
	ret := _m.Called(ctx, roleID, permID)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string) error); ok {
		r0 = rf(ctx, roleID, permID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// RemoveLegacyPermissionDetails provides a mock function with given fields: ctx, roleID, legacyPermID
func (_m *RolesAPI) RemoveLegacyPermissionDetails(ctx context.Context, roleID string, legacyPermID string) error {
	ret := _m.Called(ctx, roleID, legacyPermID)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string) error); ok {
		r0 = rf(ctx, roleID, legacyPermID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// RemovePermission provides a mock function with given fields: ctx, roleID, rolePermissionID
func (_m *RolesAPI) RemovePermission(ctx context.Context, roleID string, rolePermissionID string) error {
	ret := _m.Called(ctx, roleID, rolePermissionID)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string) error); ok {
		r0 = rf(ctx, roleID, rolePermissionID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// RemoveUserMembership provides a mock function with given fields: ctx, roleID, userID
func (_m *RolesAPI) RemoveUserMembership(ctx context.Context, roleID string, userID string) error {
	ret := _m.Called(ctx, roleID, userID)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, string) error); ok {
		r0 = rf(ctx, roleID, userID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// Update provides a mock function with given fields: ctx, roleID, options
func (_m *RolesAPI) Update(ctx context.Context, roleID string, options role.UpdateOptions) error {
	ret := _m.Called(ctx, roleID, options)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, role.UpdateOptions) error); ok {
		r0 = rf(ctx, roleID, options)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}
