From 1fa89d032316ebb1c0374e9efd6eae3ed4556359 Mon Sep 17 00:00:00 2001 From: Mark Bates Date: Fri, 1 Nov 2019 16:08:10 -0400 Subject: [PATCH] Digging the "Dancing Queen" --- here/parse_test.go | 4 ++-- parser/parser_test.go | 6 +++--- pkger_test.go | 2 +- pkging/mem/add_test.go | 2 +- pkging/mem/create_test.go | 6 +++--- pkging/mem/current_test.go | 6 +++--- pkging/mem/http_test.go | 6 +++--- pkging/mem/info_test.go | 6 +++--- pkging/mem/mem_test.go | 4 ++-- pkging/mem/mkdirall_test.go | 6 +++--- pkging/mem/open_test.go | 6 +++--- pkging/mem/remove_test.go | 6 +++--- pkging/mem/removeall_test.go | 6 +++--- pkging/mem/stat_test.go | 6 +++--- pkging/mem/walk_test.go | 6 +++--- pkging/{costello => pkgtest}/create.go | 2 +- pkging/{costello => pkgtest}/current.go | 2 +- pkging/{costello => pkgtest}/http.go | 2 +- pkging/{costello => pkgtest}/info.go | 2 +- pkging/{costello => pkgtest}/load_ref.go | 6 +++--- pkging/{costello => pkgtest}/mkdir_all.go | 2 +- pkging/{costello => pkgtest}/open.go | 2 +- .../{costello/costello.go => pkgtest/pkgtest.go} | 2 +- pkging/{costello => pkgtest}/ref.go | 4 ++-- pkging/{costello => pkgtest}/remove.go | 2 +- pkging/{costello => pkgtest}/remove_all.go | 2 +- pkging/{costello => pkgtest}/stat.go | 2 +- .../testdata/ref/actions/actions.go | 0 .../testdata/ref/assets/css/_buffalo.scss | 0 .../testdata/ref/assets/css/application.scss | 0 .../testdata/ref/assets/images/favicon.ico | Bin .../testdata/ref/assets/images/logo.svg | 0 .../testdata/ref/assets/js/application.js | 0 pkging/{costello => pkgtest}/testdata/ref/go.mod | 0 pkging/{costello => pkgtest}/testdata/ref/go.sum | 0 .../testdata/ref/locales/all.en-us.yaml | 0 pkging/{costello => pkgtest}/testdata/ref/main.go | 0 .../{costello => pkgtest}/testdata/ref/mod/mod.go | 0 .../testdata/ref/models/models.go | 0 .../testdata/ref/public/assets/.keep | 0 .../testdata/ref/public/assets/app.css | 0 .../testdata/ref/public/images/img1.png | Bin .../testdata/ref/public/index.html | 0 .../testdata/ref/public/robots.txt | 0 .../testdata/ref/templates/_flash.plush.html | 0 .../testdata/ref/templates/application.plush.html | 0 .../testdata/ref/templates/index.plush.html | 0 .../{costello => pkgtest}/testdata/ref/web/web.go | 0 pkging/{costello => pkgtest}/walk.go | 2 +- pkging/pkgutil/stuff_test.go | 14 +++++++------- pkging/stdos/create_test.go | 6 +++--- pkging/stdos/current_test.go | 6 +++--- pkging/stdos/http_test.go | 6 +++--- pkging/stdos/info_test.go | 6 +++--- pkging/stdos/mkdirall_test.go | 6 +++--- pkging/stdos/open_test.go | 6 +++--- pkging/stdos/remove_test.go | 6 +++--- pkging/stdos/removeall_test.go | 6 +++--- pkging/stdos/stat_test.go | 6 +++--- pkging/stdos/stdos_test.go | 4 ++-- pkging/stdos/walk_test.go | 6 +++--- 61 files changed, 94 insertions(+), 94 deletions(-) rename pkging/{costello => pkgtest}/create.go (97%) rename pkging/{costello => pkgtest}/current.go (92%) rename pkging/{costello => pkgtest}/http.go (98%) rename pkging/{costello => pkgtest}/info.go (93%) rename pkging/{costello => pkgtest}/load_ref.go (98%) rename pkging/{costello => pkgtest}/mkdir_all.go (96%) rename pkging/{costello => pkgtest}/open.go (97%) rename pkging/{costello/costello.go => pkgtest/pkgtest.go} (98%) rename pkging/{costello => pkgtest}/ref.go (97%) rename pkging/{costello => pkgtest}/remove.go (95%) rename pkging/{costello => pkgtest}/remove_all.go (95%) rename pkging/{costello => pkgtest}/stat.go (96%) rename pkging/{costello => pkgtest}/testdata/ref/actions/actions.go (100%) rename pkging/{costello => pkgtest}/testdata/ref/assets/css/_buffalo.scss (100%) rename pkging/{costello => pkgtest}/testdata/ref/assets/css/application.scss (100%) rename pkging/{costello => pkgtest}/testdata/ref/assets/images/favicon.ico (100%) rename pkging/{costello => pkgtest}/testdata/ref/assets/images/logo.svg (100%) rename pkging/{costello => pkgtest}/testdata/ref/assets/js/application.js (100%) rename pkging/{costello => pkgtest}/testdata/ref/go.mod (100%) rename pkging/{costello => pkgtest}/testdata/ref/go.sum (100%) rename pkging/{costello => pkgtest}/testdata/ref/locales/all.en-us.yaml (100%) rename pkging/{costello => pkgtest}/testdata/ref/main.go (100%) rename pkging/{costello => pkgtest}/testdata/ref/mod/mod.go (100%) rename pkging/{costello => pkgtest}/testdata/ref/models/models.go (100%) rename pkging/{costello => pkgtest}/testdata/ref/public/assets/.keep (100%) rename pkging/{costello => pkgtest}/testdata/ref/public/assets/app.css (100%) rename pkging/{costello => pkgtest}/testdata/ref/public/images/img1.png (100%) rename pkging/{costello => pkgtest}/testdata/ref/public/index.html (100%) rename pkging/{costello => pkgtest}/testdata/ref/public/robots.txt (100%) rename pkging/{costello => pkgtest}/testdata/ref/templates/_flash.plush.html (100%) rename pkging/{costello => pkgtest}/testdata/ref/templates/application.plush.html (100%) rename pkging/{costello => pkgtest}/testdata/ref/templates/index.plush.html (100%) rename pkging/{costello => pkgtest}/testdata/ref/web/web.go (100%) rename pkging/{costello => pkgtest}/walk.go (97%) diff --git a/here/parse_test.go b/here/parse_test.go index 484e843..b091511 100644 --- a/here/parse_test.go +++ b/here/parse_test.go @@ -7,7 +7,7 @@ import ( "testing" "github.com/markbates/pkger/here" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) @@ -16,7 +16,7 @@ func Test_Info_Parse(t *testing.T) { r := require.New(t) - app, err := costello.NewRef() + app, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(app.Dir) diff --git a/parser/parser_test.go b/parser/parser_test.go index cd4a486..a4c4ea5 100644 --- a/parser/parser_test.go +++ b/parser/parser_test.go @@ -8,7 +8,7 @@ import ( "github.com/markbates/pkger/here" "github.com/markbates/pkger/parser" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/markbates/pkger/pkging/stdos" "github.com/stretchr/testify/require" ) @@ -16,14 +16,14 @@ import ( func Test_Parser_Ref(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) disk, err := stdos.New(ref.Info) r.NoError(err) - _, err = costello.LoadFiles("/", ref, disk) + _, err = pkgtest.LoadFiles("/", ref, disk) r.NoError(err) res, err := parser.Parse(ref.Info) diff --git a/pkger_test.go b/pkger_test.go index 0507cd1..5775001 100644 --- a/pkger_test.go +++ b/pkger_test.go @@ -69,7 +69,7 @@ func Test_Walk(t *testing.T) { r := require.New(t) files := map[string]os.FileInfo{} - err := Walk("/pkging/costello/testdata/ref", func(path string, info os.FileInfo, err error) error { + err := Walk("/pkging/pkgtest/testdata/ref", func(path string, info os.FileInfo, err error) error { if err != nil { return err } diff --git a/pkging/mem/add_test.go b/pkging/mem/add_test.go index 845d2ca..342d048 100644 --- a/pkging/mem/add_test.go +++ b/pkging/mem/add_test.go @@ -20,7 +20,7 @@ func Test_Pkger_Add(t *testing.T) { r.NoError(err) var exp []os.FileInfo - root := filepath.Join(cur.Dir, "pkging", "costello", "testdata", "ref") + root := filepath.Join(cur.Dir, "pkging", "pkgtest", "testdata", "ref") err = filepath.Walk(root, func(path string, info os.FileInfo, err error) error { if err != nil { return err diff --git a/pkging/mem/create_test.go b/pkging/mem/create_test.go index 2f35e60..8950c21 100644 --- a/pkging/mem/create_test.go +++ b/pkging/mem/create_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Create(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.CreateTest(t, ref, pkg) + pkgtest.CreateTest(t, ref, pkg) } diff --git a/pkging/mem/current_test.go b/pkging/mem/current_test.go index 624a77e..316cce8 100644 --- a/pkging/mem/current_test.go +++ b/pkging/mem/current_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Current(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.CurrentTest(t, ref, pkg) + pkgtest.CurrentTest(t, ref, pkg) } diff --git a/pkging/mem/http_test.go b/pkging/mem/http_test.go index 0cd467f..279233a 100644 --- a/pkging/mem/http_test.go +++ b/pkging/mem/http_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_HTTP(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.HTTPTest(t, ref, pkg) + pkgtest.HTTPTest(t, ref, pkg) } diff --git a/pkging/mem/info_test.go b/pkging/mem/info_test.go index 719ac75..3971163 100644 --- a/pkging/mem/info_test.go +++ b/pkging/mem/info_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Info(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.InfoTest(t, ref, pkg) + pkgtest.InfoTest(t, ref, pkg) } diff --git a/pkging/mem/mem_test.go b/pkging/mem/mem_test.go index e18817f..fa64e40 100644 --- a/pkging/mem/mem_test.go +++ b/pkging/mem/mem_test.go @@ -4,12 +4,12 @@ import ( "testing" "github.com/markbates/pkger/pkging" - "github.com/markbates/pkger/pkging/costello" "github.com/markbates/pkger/pkging/mem" + "github.com/markbates/pkger/pkging/pkgtest" ) func Test_Pkger(t *testing.T) { - costello.All(t, func(ref *costello.Ref) (pkging.Pkger, error) { + pkgtest.All(t, func(ref *pkgtest.Ref) (pkging.Pkger, error) { return mem.New(ref.Info) }) } diff --git a/pkging/mem/mkdirall_test.go b/pkging/mem/mkdirall_test.go index 7f5f8db..d87515f 100644 --- a/pkging/mem/mkdirall_test.go +++ b/pkging/mem/mkdirall_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_MkdirAll(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.MkdirAllTest(t, ref, pkg) + pkgtest.MkdirAllTest(t, ref, pkg) } diff --git a/pkging/mem/open_test.go b/pkging/mem/open_test.go index b7d34fd..a68ff74 100644 --- a/pkging/mem/open_test.go +++ b/pkging/mem/open_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Open(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.OpenTest(t, ref, pkg) + pkgtest.OpenTest(t, ref, pkg) } diff --git a/pkging/mem/remove_test.go b/pkging/mem/remove_test.go index c9d32a6..f09ca6d 100644 --- a/pkging/mem/remove_test.go +++ b/pkging/mem/remove_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Remove(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.RemoveTest(t, ref, pkg) + pkgtest.RemoveTest(t, ref, pkg) } diff --git a/pkging/mem/removeall_test.go b/pkging/mem/removeall_test.go index 3d48d78..e2e90c8 100644 --- a/pkging/mem/removeall_test.go +++ b/pkging/mem/removeall_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_RemoveAll(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.RemoveAllTest(t, ref, pkg) + pkgtest.RemoveAllTest(t, ref, pkg) } diff --git a/pkging/mem/stat_test.go b/pkging/mem/stat_test.go index c2ba470..226cf8a 100644 --- a/pkging/mem/stat_test.go +++ b/pkging/mem/stat_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Stat(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.StatTest(t, ref, pkg) + pkgtest.StatTest(t, ref, pkg) } diff --git a/pkging/mem/walk_test.go b/pkging/mem/walk_test.go index 0a8dc2c..fda6e3d 100644 --- a/pkging/mem/walk_test.go +++ b/pkging/mem/walk_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Walk(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.WalkTest(t, ref, pkg) + pkgtest.WalkTest(t, ref, pkg) } diff --git a/pkging/costello/create.go b/pkging/pkgtest/create.go similarity index 97% rename from pkging/costello/create.go rename to pkging/pkgtest/create.go index 9b5bd69..cdcfbf3 100644 --- a/pkging/costello/create.go +++ b/pkging/pkgtest/create.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "io/ioutil" diff --git a/pkging/costello/current.go b/pkging/pkgtest/current.go similarity index 92% rename from pkging/costello/current.go rename to pkging/pkgtest/current.go index 27265b4..9b0e4d4 100644 --- a/pkging/costello/current.go +++ b/pkging/pkgtest/current.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "testing" diff --git a/pkging/costello/http.go b/pkging/pkgtest/http.go similarity index 98% rename from pkging/costello/http.go rename to pkging/pkgtest/http.go index e0f15c4..baa69e8 100644 --- a/pkging/costello/http.go +++ b/pkging/pkgtest/http.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "io/ioutil" diff --git a/pkging/costello/info.go b/pkging/pkgtest/info.go similarity index 93% rename from pkging/costello/info.go rename to pkging/pkgtest/info.go index d998f0d..76ce881 100644 --- a/pkging/costello/info.go +++ b/pkging/pkgtest/info.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "testing" diff --git a/pkging/costello/load_ref.go b/pkging/pkgtest/load_ref.go similarity index 98% rename from pkging/costello/load_ref.go rename to pkging/pkgtest/load_ref.go index 088b646..3346b98 100644 --- a/pkging/costello/load_ref.go +++ b/pkging/pkgtest/load_ref.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "fmt" @@ -20,7 +20,7 @@ func LoadFile(name string, ref *Ref, pkg pkging.Pkger) (os.FileInfo, error) { root := filepath.Join( her.Module.Dir, "pkging", - "costello", + "pkgtest", "testdata", "ref", name, @@ -81,7 +81,7 @@ func LoadFiles(name string, ref *Ref, pkg pkging.Pkger) ([]os.FileInfo, error) { root := filepath.Join( her.Module.Dir, "pkging", - "costello", + "pkgtest", "testdata", "ref", name, diff --git a/pkging/costello/mkdir_all.go b/pkging/pkgtest/mkdir_all.go similarity index 96% rename from pkging/costello/mkdir_all.go rename to pkging/pkgtest/mkdir_all.go index d9c0407..fae22f3 100644 --- a/pkging/costello/mkdir_all.go +++ b/pkging/pkgtest/mkdir_all.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "testing" diff --git a/pkging/costello/open.go b/pkging/pkgtest/open.go similarity index 97% rename from pkging/costello/open.go rename to pkging/pkgtest/open.go index f25e2bb..79fdf83 100644 --- a/pkging/costello/open.go +++ b/pkging/pkgtest/open.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "fmt" diff --git a/pkging/costello/costello.go b/pkging/pkgtest/pkgtest.go similarity index 98% rename from pkging/costello/costello.go rename to pkging/pkgtest/pkgtest.go index ab107ad..d852fda 100644 --- a/pkging/costello/costello.go +++ b/pkging/pkgtest/pkgtest.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "fmt" diff --git a/pkging/costello/ref.go b/pkging/pkgtest/ref.go similarity index 97% rename from pkging/costello/ref.go rename to pkging/pkgtest/ref.go index 7264105..b95e503 100644 --- a/pkging/costello/ref.go +++ b/pkging/pkgtest/ref.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "crypto/rand" @@ -24,7 +24,7 @@ func NewRef() (*Ref, error) { root := filepath.Join( her.Module.Dir, "pkging", - "costello", + "pkgtest", "testdata", "ref") diff --git a/pkging/costello/remove.go b/pkging/pkgtest/remove.go similarity index 95% rename from pkging/costello/remove.go rename to pkging/pkgtest/remove.go index e46c464..ee344c2 100644 --- a/pkging/costello/remove.go +++ b/pkging/pkgtest/remove.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "testing" diff --git a/pkging/costello/remove_all.go b/pkging/pkgtest/remove_all.go similarity index 95% rename from pkging/costello/remove_all.go rename to pkging/pkgtest/remove_all.go index 4e170ab..a74c717 100644 --- a/pkging/costello/remove_all.go +++ b/pkging/pkgtest/remove_all.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "testing" diff --git a/pkging/costello/stat.go b/pkging/pkgtest/stat.go similarity index 96% rename from pkging/costello/stat.go rename to pkging/pkgtest/stat.go index 5f6e77f..0bba541 100644 --- a/pkging/costello/stat.go +++ b/pkging/pkgtest/stat.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "os" diff --git a/pkging/costello/testdata/ref/actions/actions.go b/pkging/pkgtest/testdata/ref/actions/actions.go similarity index 100% rename from pkging/costello/testdata/ref/actions/actions.go rename to pkging/pkgtest/testdata/ref/actions/actions.go diff --git a/pkging/costello/testdata/ref/assets/css/_buffalo.scss b/pkging/pkgtest/testdata/ref/assets/css/_buffalo.scss similarity index 100% rename from pkging/costello/testdata/ref/assets/css/_buffalo.scss rename to pkging/pkgtest/testdata/ref/assets/css/_buffalo.scss diff --git a/pkging/costello/testdata/ref/assets/css/application.scss b/pkging/pkgtest/testdata/ref/assets/css/application.scss similarity index 100% rename from pkging/costello/testdata/ref/assets/css/application.scss rename to pkging/pkgtest/testdata/ref/assets/css/application.scss diff --git a/pkging/costello/testdata/ref/assets/images/favicon.ico b/pkging/pkgtest/testdata/ref/assets/images/favicon.ico similarity index 100% rename from pkging/costello/testdata/ref/assets/images/favicon.ico rename to pkging/pkgtest/testdata/ref/assets/images/favicon.ico diff --git a/pkging/costello/testdata/ref/assets/images/logo.svg b/pkging/pkgtest/testdata/ref/assets/images/logo.svg similarity index 100% rename from pkging/costello/testdata/ref/assets/images/logo.svg rename to pkging/pkgtest/testdata/ref/assets/images/logo.svg diff --git a/pkging/costello/testdata/ref/assets/js/application.js b/pkging/pkgtest/testdata/ref/assets/js/application.js similarity index 100% rename from pkging/costello/testdata/ref/assets/js/application.js rename to pkging/pkgtest/testdata/ref/assets/js/application.js diff --git a/pkging/costello/testdata/ref/go.mod b/pkging/pkgtest/testdata/ref/go.mod similarity index 100% rename from pkging/costello/testdata/ref/go.mod rename to pkging/pkgtest/testdata/ref/go.mod diff --git a/pkging/costello/testdata/ref/go.sum b/pkging/pkgtest/testdata/ref/go.sum similarity index 100% rename from pkging/costello/testdata/ref/go.sum rename to pkging/pkgtest/testdata/ref/go.sum diff --git a/pkging/costello/testdata/ref/locales/all.en-us.yaml b/pkging/pkgtest/testdata/ref/locales/all.en-us.yaml similarity index 100% rename from pkging/costello/testdata/ref/locales/all.en-us.yaml rename to pkging/pkgtest/testdata/ref/locales/all.en-us.yaml diff --git a/pkging/costello/testdata/ref/main.go b/pkging/pkgtest/testdata/ref/main.go similarity index 100% rename from pkging/costello/testdata/ref/main.go rename to pkging/pkgtest/testdata/ref/main.go diff --git a/pkging/costello/testdata/ref/mod/mod.go b/pkging/pkgtest/testdata/ref/mod/mod.go similarity index 100% rename from pkging/costello/testdata/ref/mod/mod.go rename to pkging/pkgtest/testdata/ref/mod/mod.go diff --git a/pkging/costello/testdata/ref/models/models.go b/pkging/pkgtest/testdata/ref/models/models.go similarity index 100% rename from pkging/costello/testdata/ref/models/models.go rename to pkging/pkgtest/testdata/ref/models/models.go diff --git a/pkging/costello/testdata/ref/public/assets/.keep b/pkging/pkgtest/testdata/ref/public/assets/.keep similarity index 100% rename from pkging/costello/testdata/ref/public/assets/.keep rename to pkging/pkgtest/testdata/ref/public/assets/.keep diff --git a/pkging/costello/testdata/ref/public/assets/app.css b/pkging/pkgtest/testdata/ref/public/assets/app.css similarity index 100% rename from pkging/costello/testdata/ref/public/assets/app.css rename to pkging/pkgtest/testdata/ref/public/assets/app.css diff --git a/pkging/costello/testdata/ref/public/images/img1.png b/pkging/pkgtest/testdata/ref/public/images/img1.png similarity index 100% rename from pkging/costello/testdata/ref/public/images/img1.png rename to pkging/pkgtest/testdata/ref/public/images/img1.png diff --git a/pkging/costello/testdata/ref/public/index.html b/pkging/pkgtest/testdata/ref/public/index.html similarity index 100% rename from pkging/costello/testdata/ref/public/index.html rename to pkging/pkgtest/testdata/ref/public/index.html diff --git a/pkging/costello/testdata/ref/public/robots.txt b/pkging/pkgtest/testdata/ref/public/robots.txt similarity index 100% rename from pkging/costello/testdata/ref/public/robots.txt rename to pkging/pkgtest/testdata/ref/public/robots.txt diff --git a/pkging/costello/testdata/ref/templates/_flash.plush.html b/pkging/pkgtest/testdata/ref/templates/_flash.plush.html similarity index 100% rename from pkging/costello/testdata/ref/templates/_flash.plush.html rename to pkging/pkgtest/testdata/ref/templates/_flash.plush.html diff --git a/pkging/costello/testdata/ref/templates/application.plush.html b/pkging/pkgtest/testdata/ref/templates/application.plush.html similarity index 100% rename from pkging/costello/testdata/ref/templates/application.plush.html rename to pkging/pkgtest/testdata/ref/templates/application.plush.html diff --git a/pkging/costello/testdata/ref/templates/index.plush.html b/pkging/pkgtest/testdata/ref/templates/index.plush.html similarity index 100% rename from pkging/costello/testdata/ref/templates/index.plush.html rename to pkging/pkgtest/testdata/ref/templates/index.plush.html diff --git a/pkging/costello/testdata/ref/web/web.go b/pkging/pkgtest/testdata/ref/web/web.go similarity index 100% rename from pkging/costello/testdata/ref/web/web.go rename to pkging/pkgtest/testdata/ref/web/web.go diff --git a/pkging/costello/walk.go b/pkging/pkgtest/walk.go similarity index 97% rename from pkging/costello/walk.go rename to pkging/pkgtest/walk.go index 515024f..cfee163 100644 --- a/pkging/costello/walk.go +++ b/pkging/pkgtest/walk.go @@ -1,4 +1,4 @@ -package costello +package pkgtest import ( "os" diff --git a/pkging/pkgutil/stuff_test.go b/pkging/pkgutil/stuff_test.go index 28b29f3..0b1b35c 100644 --- a/pkging/pkgutil/stuff_test.go +++ b/pkging/pkgutil/stuff_test.go @@ -6,8 +6,8 @@ import ( "testing" "github.com/markbates/pkger/parser" - "github.com/markbates/pkger/pkging/costello" "github.com/markbates/pkger/pkging/mem" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/markbates/pkger/pkging/stdos" "github.com/stretchr/testify/require" ) @@ -15,14 +15,14 @@ import ( func Test_Stuff(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) disk, err := stdos.New(ref.Info) r.NoError(err) - infos, err := costello.LoadFiles("/", ref, disk) + infos, err := pkgtest.LoadFiles("/", ref, disk) r.NoError(err) r.Len(infos, 34) @@ -48,10 +48,10 @@ func Test_Stuff(t *testing.T) { pkg, err := mem.UnmarshalEmbed(bb.Bytes()) r.NoError(err) - costello.CurrentTest(t, ref, pkg) - costello.InfoTest(t, ref, pkg) - costello.OpenTest(t, ref, pkg) - costello.WalkTest(t, ref, pkg) + pkgtest.CurrentTest(t, ref, pkg) + pkgtest.InfoTest(t, ref, pkg) + pkgtest.OpenTest(t, ref, pkg) + pkgtest.WalkTest(t, ref, pkg) _, err = pkg.Stat("/go.mod") r.NoError(err) diff --git a/pkging/stdos/create_test.go b/pkging/stdos/create_test.go index b06a8be..e0df155 100644 --- a/pkging/stdos/create_test.go +++ b/pkging/stdos/create_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Create(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.CreateTest(t, ref, pkg) + pkgtest.CreateTest(t, ref, pkg) } diff --git a/pkging/stdos/current_test.go b/pkging/stdos/current_test.go index bd6c2ef..e9160bb 100644 --- a/pkging/stdos/current_test.go +++ b/pkging/stdos/current_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Current(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.CurrentTest(t, ref, pkg) + pkgtest.CurrentTest(t, ref, pkg) } diff --git a/pkging/stdos/http_test.go b/pkging/stdos/http_test.go index 52f35b1..81ea489 100644 --- a/pkging/stdos/http_test.go +++ b/pkging/stdos/http_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_HTTP(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.HTTPTest(t, ref, pkg) + pkgtest.HTTPTest(t, ref, pkg) } diff --git a/pkging/stdos/info_test.go b/pkging/stdos/info_test.go index d83ba35..c14383c 100644 --- a/pkging/stdos/info_test.go +++ b/pkging/stdos/info_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Info(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.InfoTest(t, ref, pkg) + pkgtest.InfoTest(t, ref, pkg) } diff --git a/pkging/stdos/mkdirall_test.go b/pkging/stdos/mkdirall_test.go index eb701b9..f595fa0 100644 --- a/pkging/stdos/mkdirall_test.go +++ b/pkging/stdos/mkdirall_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_MkdirAll(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.MkdirAllTest(t, ref, pkg) + pkgtest.MkdirAllTest(t, ref, pkg) } diff --git a/pkging/stdos/open_test.go b/pkging/stdos/open_test.go index c7e7cde..ea9acb1 100644 --- a/pkging/stdos/open_test.go +++ b/pkging/stdos/open_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Open(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.OpenTest(t, ref, pkg) + pkgtest.OpenTest(t, ref, pkg) } diff --git a/pkging/stdos/remove_test.go b/pkging/stdos/remove_test.go index f42b572..01d1064 100644 --- a/pkging/stdos/remove_test.go +++ b/pkging/stdos/remove_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Remove(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.RemoveTest(t, ref, pkg) + pkgtest.RemoveTest(t, ref, pkg) } diff --git a/pkging/stdos/removeall_test.go b/pkging/stdos/removeall_test.go index 9ced5bb..d07b890 100644 --- a/pkging/stdos/removeall_test.go +++ b/pkging/stdos/removeall_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_RemoveAll(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.RemoveAllTest(t, ref, pkg) + pkgtest.RemoveAllTest(t, ref, pkg) } diff --git a/pkging/stdos/stat_test.go b/pkging/stdos/stat_test.go index 325516f..ce01ced 100644 --- a/pkging/stdos/stat_test.go +++ b/pkging/stdos/stat_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Stat(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.StatTest(t, ref, pkg) + pkgtest.StatTest(t, ref, pkg) } diff --git a/pkging/stdos/stdos_test.go b/pkging/stdos/stdos_test.go index 43a1baa..3033224 100644 --- a/pkging/stdos/stdos_test.go +++ b/pkging/stdos/stdos_test.go @@ -4,11 +4,11 @@ import ( "testing" "github.com/markbates/pkger/pkging" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" ) func Test_Pkger(t *testing.T) { - costello.All(t, func(ref *costello.Ref) (pkging.Pkger, error) { + pkgtest.All(t, func(ref *pkgtest.Ref) (pkging.Pkger, error) { return New(ref.Info) }) } diff --git a/pkging/stdos/walk_test.go b/pkging/stdos/walk_test.go index ad47915..6463073 100644 --- a/pkging/stdos/walk_test.go +++ b/pkging/stdos/walk_test.go @@ -4,19 +4,19 @@ import ( "os" "testing" - "github.com/markbates/pkger/pkging/costello" + "github.com/markbates/pkger/pkging/pkgtest" "github.com/stretchr/testify/require" ) func Test_Pkger_Walk(t *testing.T) { r := require.New(t) - ref, err := costello.NewRef() + ref, err := pkgtest.NewRef() r.NoError(err) defer os.RemoveAll(ref.Dir) pkg, err := New(ref.Info) r.NoError(err) - costello.WalkTest(t, ref, pkg) + pkgtest.WalkTest(t, ref, pkg) }