mirror of
https://github.com/zeromicro/go-zero.git
synced 2025-01-23 09:00:20 +08:00
16 lines
208 B
Go
16 lines
208 B
Go
package fs
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
)
|
|
|
|
func TestCloseOnExec(t *testing.T) {
|
|
file := os.NewFile(0, os.DevNull)
|
|
assert.NotPanics(t, func() {
|
|
CloseOnExec(file)
|
|
})
|
|
}
|