mirror of
https://github.com/yusing/godoxy.git
synced 2026-03-20 16:23:53 +01:00
refactor: simplify io code and make utils module independent
This commit is contained in:
@@ -2,14 +2,16 @@ package expect
|
||||
|
||||
import (
|
||||
"os"
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
"github.com/stretchr/testify/require"
|
||||
"github.com/yusing/go-proxy/internal/common"
|
||||
)
|
||||
|
||||
var isTest = strings.HasSuffix(os.Args[0], ".test")
|
||||
|
||||
func init() {
|
||||
if common.IsTest {
|
||||
if isTest {
|
||||
// force verbose output
|
||||
os.Args = append([]string{os.Args[0], "-test.v"}, os.Args[1:]...)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user