| Index: impl/dummy/dummy.go
|
| diff --git a/impl/dummy/dummy.go b/impl/dummy/dummy.go
|
| index a965a757e0cad00ebec60d84ad84691bdec00d68..d5badcfab682b9f8d88c2fd8677dc2db19f99dee 100644
|
| --- a/impl/dummy/dummy.go
|
| +++ b/impl/dummy/dummy.go
|
| @@ -12,6 +12,7 @@ import (
|
|
|
| "github.com/luci/gae/service/datastore"
|
| "github.com/luci/gae/service/info"
|
| + "github.com/luci/gae/service/mail"
|
| "github.com/luci/gae/service/memcache"
|
| "github.com/luci/gae/service/taskqueue"
|
| "github.com/luci/gae/service/user"
|
| @@ -48,6 +49,8 @@ func ni() error {
|
| iface = "Datastore"
|
| case "i":
|
| iface = "Info"
|
| + case "m":
|
| + iface = "Mail"
|
| case "mc":
|
| iface = "Memcache"
|
| case "tq":
|
| @@ -182,3 +185,18 @@ var dummyUserInst = u{}
|
| // Every method panics with a message containing the name of the method which
|
| // was unimplemented.
|
| func User() user.Interface { return dummyUserInst }
|
| +
|
| +////////////////////////////////////// m ///////////////////////////////////////
|
| +
|
| +type m struct{}
|
| +
|
| +func (m) Send(*mail.Message) error { panic(ni()) }
|
| +func (m) SendToAdmins(*mail.Message) error { panic(ni()) }
|
| +func (m) Testable() mail.Testable { panic(ni()) }
|
| +
|
| +var dummyMailInst = m{}
|
| +
|
| +// Mail returns a dummy mail.Interface implementation suitable for embedding.
|
| +// Every method panics with a message containing the name of the method which
|
| +// was unimplemented.
|
| +func Mail() mail.Interface { return dummyMailInst }
|
|
|