2019-09-01 00:00:24 +03:00
|
|
|
package memfs
|
|
|
|
|
|
|
|
import (
|
2019-09-01 05:45:22 +03:00
|
|
|
"testing"
|
2019-09-01 00:00:24 +03:00
|
|
|
|
|
|
|
"github.com/markbates/pkger/fs/fstest"
|
|
|
|
"github.com/markbates/pkger/here"
|
2019-09-01 05:45:22 +03:00
|
|
|
"github.com/stretchr/testify/require"
|
2019-09-01 00:00:24 +03:00
|
|
|
)
|
|
|
|
|
2019-09-01 05:45:22 +03:00
|
|
|
func Test_FS(t *testing.T) {
|
|
|
|
r := require.New(t)
|
|
|
|
|
|
|
|
info, err := here.Current()
|
|
|
|
r.NoError(err)
|
|
|
|
|
|
|
|
myfs, err := New(info)
|
|
|
|
r.NoError(err)
|
|
|
|
|
|
|
|
suite, err := fstest.NewFileSystem(myfs)
|
|
|
|
r.NoError(err)
|
2019-09-01 00:00:24 +03:00
|
|
|
|
2019-09-01 05:45:22 +03:00
|
|
|
suite.Test(t)
|
2019-09-01 00:00:24 +03:00
|
|
|
}
|