diff --git a/parser_test.go b/parser_test.go index 83c2bbb..529d1a0 100644 --- a/parser_test.go +++ b/parser_test.go @@ -4,6 +4,7 @@ import ( "encoding/json" "log" "regexp" + "strconv" "strings" "testing" @@ -43,6 +44,8 @@ func (tt *Toutiao) ToDoParser(adstring string) (string, error) { for _, data := range adlist { data = strings.Trim(data, "\"") + unq, _ := strconv.Unquote("\"" + data + "\"") + data = unq var v interface{} json.Unmarshal([]byte(data), &v) spew.Dump(v)