2019-10-31 18:06:20 +03:00
|
|
|
package stdos
|
|
|
|
|
|
|
|
import (
|
2019-11-01 00:20:15 +03:00
|
|
|
"os"
|
2019-10-31 18:06:20 +03:00
|
|
|
"testing"
|
|
|
|
|
|
|
|
"github.com/markbates/pkger/pkging/costello"
|
|
|
|
"github.com/stretchr/testify/require"
|
|
|
|
)
|
|
|
|
|
|
|
|
func Test_Pkger_Current(t *testing.T) {
|
|
|
|
r := require.New(t)
|
|
|
|
|
|
|
|
ref, err := costello.NewRef()
|
|
|
|
r.NoError(err)
|
2019-11-01 00:20:15 +03:00
|
|
|
defer os.RemoveAll(ref.Dir)
|
2019-10-31 18:06:20 +03:00
|
|
|
|
2019-11-01 00:20:15 +03:00
|
|
|
pkg, err := New(ref.Info)
|
2019-10-31 18:06:20 +03:00
|
|
|
r.NoError(err)
|
|
|
|
|
|
|
|
costello.CurrentTest(t, ref, pkg)
|
|
|
|
}
|