Created
August 9, 2020 06:46
-
-
Save ShaileshSurya/ca0f4dc5db537ac3188caba26932d5d5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package dependfactory | |
import ( | |
dep "github.com/ShaileshSurya/go-external-mocking/dependfactory/dependency" | |
"github.com/ShaileshSurya/go-external-mocking/dependfactory/interfacer" | |
"github.com/ShaileshSurya/go-external-mocking/dependfactory/mock" | |
) | |
// GetExternal ... | |
func GetExternal(env string) interfacer.External { | |
if env == "test" { | |
return mock.MockExternal{} | |
} | |
return dep.External{} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment