コード例 #1
0
        public void GoodPendingDownload()
        {
            var res = new MockResponse()
            {
                ContentType = "application/json",
                Code        = System.Net.HttpStatusCode.Accepted,
                Body        = ""
            };

            using (var c = new TestClient(res))
            {
                var actualResult = c.Client.Export.Download(123);

                var expectedResult = new SlideRoom.API.Resources.DownloadResult()
                {
                    Pending      = true,
                    ExportStream = null
                };

                Assert.AreEqual(actualResult.ExportStream, expectedResult.ExportStream);
                Assert.AreEqual(actualResult.Pending, expectedResult.Pending);
            }
        }
コード例 #2
0
ファイル: Download.cs プロジェクト: ryanlsmith/api-csharp
        public void GoodPendingDownload()
        {
            var res = new MockResponse()
            {
                ContentType = "application/json",
                Code = System.Net.HttpStatusCode.Accepted,
                Body = ""
            };

            using (var c = new TestClient(res))
            {
                var actualResult = c.Client.Export.Download(123);

                var expectedResult = new SlideRoom.API.Resources.DownloadResult()
                {
                    Pending = true,
                    ExportStream = null
                };

                Assert.AreEqual(actualResult.ExportStream, expectedResult.ExportStream);
                Assert.AreEqual(actualResult.Pending, expectedResult.Pending);
            }
        }