mirror of
https://github.com/httprunner/httprunner.git
synced 2026-07-09 06:23:52 +08:00
fix: EventTracking ev field type
This commit is contained in:
@@ -8,6 +8,7 @@ func TestSendEvents(t *testing.T) {
|
||||
event := EventTracking{
|
||||
Category: "unittest",
|
||||
Action: "SendEvents",
|
||||
Value: "123",
|
||||
}
|
||||
err := gaClient.SendEvent(event)
|
||||
if err != nil {
|
||||
@@ -20,9 +21,10 @@ func TestStructToUrlValues(t *testing.T) {
|
||||
Category: "unittest",
|
||||
Action: "convert",
|
||||
Label: "StructToUrlValues",
|
||||
Value: "123",
|
||||
}
|
||||
val := structToUrlValues(event)
|
||||
if val.Encode() != "ea=convert&ec=unittest&el=StructToUrlValues" {
|
||||
if val.Encode() != "ea=convert&ec=unittest&el=StructToUrlValues&ev=123" {
|
||||
t.Fail()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user