Skip to content

Commit

Permalink
feat: Move all files from pkg/openfeature to openfeature. (#232)
Browse files Browse the repository at this point in the history
Move all files from pkg/openfeature to openfeature.

Move the package from being
github.com/open-feature/go-sdk/pkg/openfeature, which has an unnecessary
pkg in the import path, to github.com/open-feature/go-sdk/openfeature,
without the unnecessary "pkg" in the import path.

The existing github.com/open-feature/go-sdk/pkg/openfeature package is
now a compatibility shell; exported types, constants, variables, and
functions are now aliased to the new
github.com/open-feature/go-sdk/openfeature equivalents in a way that
will pass equality checks, and types are interchangeable between both
packages. No logic or tests live in the package anymore, only the
exported identifiers, which call through to the new package for
behavior.

The memprovider package, similarly, has moved.

Signed-off-by: Paddy Carver <[email protected]>
  • Loading branch information
paddycarver authored Nov 20, 2023
1 parent 34fb9d9 commit 991726c
Show file tree
Hide file tree
Showing 38 changed files with 2,044 additions and 1,360 deletions.
4 changes: 2 additions & 2 deletions e2e/common_test.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package e2e_test

import (
"github.com/open-feature/go-sdk/pkg/openfeature"
"github.com/open-feature/go-sdk/pkg/openfeature/memprovider"
"github.com/open-feature/go-sdk/openfeature"
"github.com/open-feature/go-sdk/openfeature/memprovider"
)

// ctxFunction is a context based evaluation callback
Expand Down
4 changes: 2 additions & 2 deletions e2e/evaluation_fuzz_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"strings"
"testing"

"github.com/open-feature/go-sdk/pkg/openfeature"
"github.com/open-feature/go-sdk/pkg/openfeature/memprovider"
"github.com/open-feature/go-sdk/openfeature"
"github.com/open-feature/go-sdk/openfeature/memprovider"
)

func setupFuzzClient(f *testing.F) *openfeature.Client {
Expand Down
4 changes: 2 additions & 2 deletions e2e/evaluation_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"testing"

"github.com/cucumber/godog"
"github.com/open-feature/go-sdk/pkg/openfeature"
"github.com/open-feature/go-sdk/pkg/openfeature/memprovider"
"github.com/open-feature/go-sdk/openfeature"
"github.com/open-feature/go-sdk/openfeature/memprovider"
)

var client = openfeature.NewClient("evaluation tests")
Expand Down
2 changes: 1 addition & 1 deletion pkg/openfeature/api.go → openfeature/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"sync"

"github.com/go-logr/logr"
"github.com/open-feature/go-sdk/pkg/openfeature/internal"
"github.com/open-feature/go-sdk/openfeature/internal"
"golang.org/x/exp/maps"
)

Expand Down
Loading

0 comments on commit 991726c

Please sign in to comment.