feat: add copy file to local

This commit is contained in:
ᴍᴏᴏɴD4ʀᴋ committed 2022-04-11 19:57:40 +08:00
1 parent 8b8cab4393
commit 77545627e3
18 files changed
+83 -258

No files matched your search

+1 -1
View File
@@ -18,7 +18,7 @@ type outPutter struct {
csv bool
}
func NewOutPutter(flag string) *outPutter {
func New(flag string) *outPutter {
o := &outPutter{}
if flag == "json" {
o.json = true
+2 -2
View File
@@ -6,9 +6,9 @@ import (
)
func TestNewOutPutter(t *testing.T) {
out := NewOutPutter("json")
out := New("json")
if out == nil {
t.Error("NewOutPutter() returned nil")
t.Error("New() returned nil")
}
f, err := out.CreateFile("results", "test.json")
if err != nil {