mirror of
https://gitee.com/johng/gf
synced 2026-06-06 16:21:40 +08:00
26 lines
743 B
Go
26 lines
743 B
Go
|
|
// Copyright 2019 gf Author(https://github.com/gogf/gf). All Rights Reserved.
|
||
|
|
//
|
||
|
|
// This Source Code Form is subject to the terms of the MIT License.
|
||
|
|
// If a copy of the MIT was not distributed with this file,
|
||
|
|
// You can obtain one at https://github.com/gogf/gf.
|
||
|
|
|
||
|
|
package gres_test
|
||
|
|
|
||
|
|
import (
|
||
|
|
"github.com/gogf/gf/debug/gdebug"
|
||
|
|
"github.com/gogf/gf/os/gfile"
|
||
|
|
"github.com/gogf/gf/os/gres"
|
||
|
|
"github.com/gogf/gf/test/gtest"
|
||
|
|
"testing"
|
||
|
|
)
|
||
|
|
|
||
|
|
func Test_Export(t *testing.T) {
|
||
|
|
gtest.Case(t, func() {
|
||
|
|
srcPath := gfile.Dir(gdebug.CallerFilePath()) + "/testdata/files"
|
||
|
|
goFilePath := gfile.Dir(gdebug.CallerFilePath()) + "/testdata/testdata.go"
|
||
|
|
pkgName := "testdata"
|
||
|
|
err := gres.Export(srcPath, goFilePath, pkgName)
|
||
|
|
gtest.Assert(err, nil)
|
||
|
|
})
|
||
|
|
}
|