37 references to InvocationMessage
Microsoft.AspNetCore.Components.Server.Tests (3)
src\SignalR\common\SignalR.Common\test\Internal\Protocol\MessagePackHubProtocolTestBase.cs (3)
65
message: new
InvocationMessage
("xyz", "method", Array.Empty<object>()),
239
var expectedMessage = new
InvocationMessage
("xyz", "method", Array.Empty<object>());
415
new MessageSizeTestData("InvocationMessage_WithInvocationId", new
InvocationMessage
("1", "Target", new object[] { 1 }), 16),
Microsoft.AspNetCore.SignalR.Common (1)
Protocol\HubMethodInvocationMessage.cs (1)
70
:
this
(null, target, arguments)
Microsoft.AspNetCore.SignalR.Common.Tests (16)
Internal\Protocol\JsonHubProtocolTests.cs (2)
212
new JsonProtocolTestData("InvocationMessage_HasFloatArgument", new
InvocationMessage
(null, "Target", new object[] { 1, "Foo", 2.0f }), true, true, "{\"type\":1,\"target\":\"Target\",\"arguments\":[1,\"Foo\",2]}"),
213
new JsonProtocolTestData("InvocationMessage_HasHeaders", AddHeaders(TestHeaders, new
InvocationMessage
("123", "Target", new object[] { 1, "Foo", 2.0f })), true, true, "{\"type\":1," + SerializedHeaders + ",\"invocationId\":\"123\",\"target\":\"Target\",\"arguments\":[1,\"Foo\",2]}"),
Internal\Protocol\JsonHubProtocolTestsBase.cs (9)
32
new JsonProtocolTestData("InvocationMessage_HasInvocationId", new
InvocationMessage
("123", "Target", new object[] { 1, "Foo" }), true, true, "{\"type\":1,\"invocationId\":\"123\",\"target\":\"Target\",\"arguments\":[1,\"Foo\"]}"),
33
new JsonProtocolTestData("InvocationMessage_HasBoolArgument", new
InvocationMessage
(null, "Target", new object[] { true }), true, true, "{\"type\":1,\"target\":\"Target\",\"arguments\":[true]}"),
34
new JsonProtocolTestData("InvocationMessage_HasNullArgument", new
InvocationMessage
(null, "Target", new object[] { null }), true, true, "{\"type\":1,\"target\":\"Target\",\"arguments\":[null]}"),
41
new JsonProtocolTestData("InvocationMessage_HasCustomArgumentWithNoCamelCase", new
InvocationMessage
(null, "Target", new object[] { new CustomObject() }), false, true, "{\"type\":1,\"target\":\"Target\",\"arguments\":[{\"StringProp\":\"SignalR!\",\"DoubleProp\":6.2831853071,\"IntProp\":42,\"DateTimeProp\":\"2017-04-11T00:00:00Z\",\"ByteArrProp\":\"AQID\"}]}"),
42
new JsonProtocolTestData("InvocationMessage_HasCustomArgumentWithNullValueIgnore", new
InvocationMessage
(null, "Target", new object[] { new CustomObject() }), true, true, "{\"type\":1,\"target\":\"Target\",\"arguments\":[{\"stringProp\":\"SignalR!\",\"doubleProp\":6.2831853071,\"intProp\":42,\"dateTimeProp\":\"2017-04-11T00:00:00Z\",\"byteArrProp\":\"AQID\"}]}"),
43
new JsonProtocolTestData("InvocationMessage_HasCustomArgumentWithNullValueIgnoreAndNoCamelCase", new
InvocationMessage
(null, "Target", new object[] { new CustomObject() }), false, false, "{\"type\":1,\"target\":\"Target\",\"arguments\":[{\"StringProp\":\"SignalR!\",\"DoubleProp\":6.2831853071,\"IntProp\":42,\"DateTimeProp\":\"2017-04-11T00:00:00Z\",\"NullProp\":null,\"ByteArrProp\":\"AQID\"}]}"),
44
new JsonProtocolTestData("InvocationMessage_HasCustomArgumentWithNullValueInclude", new
InvocationMessage
(null, "Target", new object[] { new CustomObject() }), true, false, "{\"type\":1,\"target\":\"Target\",\"arguments\":[{\"stringProp\":\"SignalR!\",\"doubleProp\":6.2831853071,\"intProp\":42,\"dateTimeProp\":\"2017-04-11T00:00:00Z\",\"nullProp\":null,\"byteArrProp\":\"AQID\"}]}"),
349
JsonHubProtocol.WriteMessage(new
InvocationMessage
("123", "Target", new object[] { obj }), writer);
363
new MessageSizeTestData("InvocationMessage_WithInvocationId", new
InvocationMessage
("1", "Target", new object[] { 1 }), 64),
Internal\Protocol\MessagePackHubProtocolTestBase.cs (3)
65
message: new
InvocationMessage
("xyz", "method", Array.Empty<object>()),
239
var expectedMessage = new
InvocationMessage
("xyz", "method", Array.Empty<object>());
415
new MessageSizeTestData("InvocationMessage_WithInvocationId", new
InvocationMessage
("1", "Target", new object[] { 1 }), 16),
Internal\Protocol\NewtonsoftJsonHubProtocolTests.cs (2)
98
new JsonProtocolTestData("InvocationMessage_HasFloatArgument", new
InvocationMessage
(null, "Target", new object[] { 1, "Foo", 2.0f }), true, true, "{\"type\":1,\"target\":\"Target\",\"arguments\":[1,\"Foo\",2.0]}"),
99
new JsonProtocolTestData("InvocationMessage_HasHeaders", AddHeaders(TestHeaders, new
InvocationMessage
("123", "Target", new object[] { 1, "Foo", 2.0f })), true, true, "{\"type\":1," + SerializedHeaders + ",\"invocationId\":\"123\",\"target\":\"Target\",\"arguments\":[1,\"Foo\",2.0]}"),
Microsoft.AspNetCore.SignalR.Core (1)
DefaultHubLifetimeManager.cs (1)
358
var message = new
InvocationMessage
(invocationId, methodName, args);
Microsoft.AspNetCore.SignalR.Microbenchmarks (5)
DefaultHubDispatcherBenchmark.cs (5)
215
return _dispatcher.DispatchMessageAsync(_connectionContext, new
InvocationMessage
("123", "Invocation", Array.Empty<object>()));
221
return _dispatcher.DispatchMessageAsync(_connectionContext, new
InvocationMessage
("123", "InvocationAsync", Array.Empty<object>()));
227
return _dispatcher.DispatchMessageAsync(_connectionContext, new
InvocationMessage
("123", "InvocationReturnValue", Array.Empty<object>()));
233
return _dispatcher.DispatchMessageAsync(_connectionContext, new
InvocationMessage
("123", "InvocationReturnAsync", Array.Empty<object>()));
239
return _dispatcher.DispatchMessageAsync(_connectionContext, new
InvocationMessage
("123", "InvocationValueTaskAsync", Array.Empty<object>()));
Microsoft.AspNetCore.SignalR.Specification.Tests (1)
src\SignalR\common\testassets\Tests.Utils\TestClient.cs (1)
207
return SendHubMessageAsync(new
InvocationMessage
(invocationId, methodName, args) { Headers = headers });
Microsoft.AspNetCore.SignalR.StackExchangeRedis (2)
Internal\RedisProtocol.cs (1)
72
WriteHubMessage(ref writer, new
InvocationMessage
(invocationId, methodName, args));
RedisHubLifetimeManager.cs (1)
410
var message = new
InvocationMessage
(invocationId, methodName, args);
Microsoft.AspNetCore.SignalR.Tests (7)
HubConnectionHandlerTests.ClientResult.cs (7)
25
var invocationId = await client.SendHubMessageAsync(new
InvocationMessage
("1", nameof(MethodHub.GetClientResult), new object[] { 5 })).DefaultTimeout();
58
var invocationId = await client.SendHubMessageAsync(new
InvocationMessage
("1", nameof(MethodHub.GetClientResult), new object[] { 5 })).DefaultTimeout();
208
var invocationId = await client.SendHubMessageAsync(new
InvocationMessage
(
244
_ = await client.SendHubMessageAsync(new
InvocationMessage
("1", nameof(MethodHub.BlockingMethod), Array.Empty<object>())).DefaultTimeout();
247
var invocationId = await client.SendHubMessageAsync(new
InvocationMessage
("2", nameof(MethodHub.GetClientResult), new object[] { 5 })).DefaultTimeout();
248
var invocationId2 = await client.SendHubMessageAsync(new
InvocationMessage
("3", nameof(MethodHub.GetClientResult), new object[] { 5 })).DefaultTimeout();
249
var invocationId3 = await client.SendHubMessageAsync(new
InvocationMessage
("4", nameof(MethodHub.GetClientResult), new object[] { 5 })).DefaultTimeout();
Microsoft.AspNetCore.SignalR.Tests.Utils (1)
TestClient.cs (1)
207
return SendHubMessageAsync(new
InvocationMessage
(invocationId, methodName, args) { Headers = headers });