Files
play-with-docker/pwd/tasks_mock_test.go
Jonathan Leibiusky @xetorthio e9911abf94 Storage has now it's own package.
Remove global `sessions` map and use configured storage.
Add a `types` package so both `pwd` and `storage` can access without
circular dependencies.
Now the session is prepared when requested and not on load.
2017-06-15 16:09:41 -03:00

20 lines
369 B
Go

package pwd
import "github.com/play-with-docker/play-with-docker/pwd/types"
type mockTasks struct {
schedule func(s *types.Session)
unschedule func(s *types.Session)
}
func (m *mockTasks) Schedule(s *types.Session) {
if m.schedule != nil {
m.schedule(s)
}
}
func (m *mockTasks) Unschedule(s *types.Session) {
if m.unschedule != nil {
m.unschedule(s)
}
}