mock

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 5, 2022 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AlwaysAllow added in v0.1.1

type AlwaysAllow struct{}

func (*AlwaysAllow) IsAllowed added in v0.1.1

func (c *AlwaysAllow) IsAllowed(dreq *authz.DecisionRequest) (bool, error)

type AlwaysDeny added in v0.1.1

type AlwaysDeny struct{}

func (*AlwaysDeny) IsAllowed added in v0.1.1

func (c *AlwaysDeny) IsAllowed(dreq *authz.DecisionRequest) (bool, error)

type TaskService

type TaskService struct {
	TaskFn      func(id int) (*domain.Task, error)
	TaskInvoked bool

	TasksFn      func() ([]*domain.Task, error)
	TasksInvoked bool

	CreateTaskFn      func(t *domain.Task) error
	CreateTaskInvoked bool

	DeleteTaskFn      func(id int) error
	DeleteTaskInvoked bool

	DeleteTasksFn      func() error
	DeleteTasksInvoked bool
}

func (*TaskService) CreateTask

func (s *TaskService) CreateTask(t *domain.Task) error

func (*TaskService) DeleteTask

func (s *TaskService) DeleteTask(id int) error

func (*TaskService) DeleteTasks

func (s *TaskService) DeleteTasks() error

func (*TaskService) Task

func (s *TaskService) Task(id int) (*domain.Task, error)

func (*TaskService) Tasks

func (s *TaskService) Tasks() ([]*domain.Task, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL