forked from urdt/ussd
use build tag to define account service
This commit is contained in:
parent
e30a7ad3e3
commit
c6227acba1
13
internal/testutil/tag_offline.go
Normal file
13
internal/testutil/tag_offline.go
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
// +build !online
|
||||||
|
|
||||||
|
package testutil
|
||||||
|
|
||||||
|
import (
|
||||||
|
"git.grassecon.net/urdt/ussd/internal/handlers/server"
|
||||||
|
)
|
||||||
|
|
||||||
|
var AccountService server.AccountServiceInterface
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
AccountService = &server.MockAccountService{}
|
||||||
|
}
|
11
internal/testutil/tag_online.go
Normal file
11
internal/testutil/tag_online.go
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
// +build online
|
||||||
|
|
||||||
|
package testutil
|
||||||
|
|
||||||
|
import "git.grassecon.net/urdt/ussd/internal/handlers/server"
|
||||||
|
|
||||||
|
var AccountService server.AccountServiceInterface
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
AccountService = &server.AccountService{}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user