public void Test_OK_IsOK() { MySame ms = new MySame(); _Server = new IPCServer<ITheSame>("Test",ms, "Test"); IPCClient<ITheSame> target = new IPCClient<ITheSame>("Test", "Test"); ITheSame res = target.GetService(); res.Should().NotBeNull(); res.Get(9).Should().Be(9); res.Get(10).Should().Be(10); }
public void Test_NotFound_WrongAdress() { MySame ms = new MySame(); _Server = new IPCServer<ITheSame>("Test", ms, "Test"); IPCClient<ITheSame> target = new IPCClient<ITheSame>("Test2", "Test"); ITheSame res = target.GetService(); res.Should().NotBeNull(); int resget = 0; Action ac = () => resget = res.Get(0); ac.ShouldThrow<EndpointNotFoundException>(); }