Skip to content

Commit

Permalink
make mismatch error clearer
Browse files Browse the repository at this point in the history
  • Loading branch information
lucix-aws committed Nov 5, 2024
1 parent 15752d0 commit 0f689b4
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions aws/middleware/user_agent_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ func TestAddUserAgentKey(t *testing.T) {
t.Fatalf("expect User-Agent to be present")
}
if ua[0] != c.Expect {
t.Error("User-Agent did not match expected")
t.Errorf("User-Agent: %q != %q", c.Expect, ua[0])
}
})
}
Expand Down Expand Up @@ -229,7 +229,7 @@ func TestAddUserAgentKeyValue(t *testing.T) {
t.Fatalf("expect User-Agent to be present")
}
if ua[0] != c.Expect {
t.Error("User-Agent did not match expected")
t.Errorf("User-Agent: %q != %q", c.Expect, ua[0])
}
})
}
Expand Down Expand Up @@ -294,7 +294,7 @@ func TestAddUserAgentFeature(t *testing.T) {
t.Fatalf("expect User-Agent to be present")
}
if ua[0] != c.Expect {
t.Errorf("User-Agent did not match expected, %v != %v", c.Expect, ua[0])
t.Errorf("User-Agent: %q != %q", c.Expect, ua[0])
}
})
}
Expand Down Expand Up @@ -347,7 +347,7 @@ func TestAddSDKAgentKey(t *testing.T) {
t.Fatalf("expect User-Agent to be present")
}
if ua[0] != c.Expect {
t.Error("User-Agent did not match expected")
t.Errorf("User-Agent: %q != %q", c.Expect, ua[0])
}
})
}
Expand Down Expand Up @@ -403,7 +403,7 @@ func TestAddSDKAgentKeyValue(t *testing.T) {
t.Fatalf("expect User-Agent to be present")
}
if ua[0] != c.Expect {
t.Error("User-Agent did not match expected")
t.Errorf("User-Agent: %q != %q", c.Expect, ua[0])
}
})
}
Expand Down Expand Up @@ -450,7 +450,7 @@ func TestAddUserAgentKey_AddToStack(t *testing.T) {
t.Fatalf("expect User-Agent to be present")
}
if ua[0] != c.Expect {
t.Error("User-Agent did not match expected")
t.Errorf("User-Agent: %q != %q", c.Expect, ua[0])
}
})
}
Expand Down Expand Up @@ -500,7 +500,7 @@ func TestAddUserAgentKeyValue_AddToStack(t *testing.T) {
t.Fatalf("expect User-Agent to be present")
}
if ua[0] != c.Expect {
t.Error("User-Agent did not match expected")
t.Errorf("User-Agent: %q != %q", c.Expect, ua[0])
}
})
}
Expand Down

0 comments on commit 0f689b4

Please sign in to comment.