mirror of
https://github.com/gogrlx/nats-server.git
synced 2026-04-02 03:38:42 -07:00
Moving inbound tracing to the caller (client.parse)
Tracing for outgoing operations is always done while holding the client lock. Signed-off-by: Matthias Hanel <mh@synadia.com>
This commit is contained in:
@@ -301,7 +301,7 @@ func TestParsePubArg(t *testing.T) {
|
||||
subject: "foo", reply: "", size: 2222, szb: "2222"},
|
||||
} {
|
||||
t.Run(test.arg, func(t *testing.T) {
|
||||
if err := c.processPub([]byte(test.arg), false); err != nil {
|
||||
if err := c.processPub([]byte(test.arg)); err != nil {
|
||||
t.Fatalf("Unexpected parse error: %v\n", err)
|
||||
}
|
||||
if !bytes.Equal(c.pa.subject, []byte(test.subject)) {
|
||||
@@ -324,7 +324,7 @@ func TestParsePubBadSize(t *testing.T) {
|
||||
c := dummyClient()
|
||||
// Setup localized max payload
|
||||
c.mpay = 32768
|
||||
if err := c.processPub([]byte("foo 2222222222222222"), false); err == nil {
|
||||
if err := c.processPub([]byte("foo 2222222222222222")); err == nil {
|
||||
t.Fatalf("Expected parse error for size too large")
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user