Пример #1
0
        public async Task PostByteArray()
        {
            using (MockHttpServer.PostByteArrayReturnByteArray(x => Task.FromResult(x)))
            {
                var input  = new byte[] { 3, 1, 8, 9, 15 };
                var client = HttpApiClient <IPostByteArray> .Create("http://localhost:8844/path");

                var result = await client.PostByteArray(input);

                Assert.IsTrue(result.SequenceEqual(input));
            }
        }