From 0f28ebd855dd0d1649ca69a59cfdc7e844e5a2dd Mon Sep 17 00:00:00 2001 From: frodriguez-adhara Date: Fri, 9 Oct 2020 13:19:29 +0200 Subject: [PATCH] initial --- pkg/main.go | 10 ++++++---- pkg/other/other.go | 4 +++- pkg/some/some.go | 3 +++ 3 files changed, 12 insertions(+), 5 deletions(-) create mode 100644 pkg/some/some.go diff --git a/pkg/main.go b/pkg/main.go index 3af0bc8..69cf035 100644 --- a/pkg/main.go +++ b/pkg/main.go @@ -1,11 +1,13 @@ package main -import "github.com/nano-adhara/test-commons/pkg/other" +import ( + "github.com/nano-adhara/test-commons/pkg/other" + "github.com/nano-adhara/test-commons/pkg/some" +) func main() { - Foo() } -func Foo() { - other.Bar() +func Foo(some some.Some) { + other.Bar(some) } diff --git a/pkg/other/other.go b/pkg/other/other.go index 258e409..fbd6939 100644 --- a/pkg/other/other.go +++ b/pkg/other/other.go @@ -1,5 +1,7 @@ package other -func Bar() { +import "github.com/nano-adhara/test-commons/pkg/some" + +func Bar(some some.Some) { } diff --git a/pkg/some/some.go b/pkg/some/some.go new file mode 100644 index 0000000..5e91c04 --- /dev/null +++ b/pkg/some/some.go @@ -0,0 +1,3 @@ +package some + +type Some struct{}