use build tag to define account service

This commit is contained in:
Carlosokumu 2024-10-09 16:46:22 +03:00
parent e30a7ad3e3
commit c6227acba1
Signed by untrusted user: carlos
GPG Key ID: 7BD6BC8160A5C953
2 changed files with 24 additions and 0 deletions

View 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{}
}

View 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{}
}