コード例 #1
0
ファイル: RetrievalsTests.cs プロジェクト: emrahm/MasterCom
        public void CreateRetrieval_Create_GetRequestId()
        {
            //arrange
            RetrievalCreateRequest retrievalCreateRequest = new RetrievalCreateRequest();

            retrievalCreateRequest.retrievalRequestReason = "6343";
            retrievalCreateRequest.docNeeded = "2";
            //act
            Retrievals retrievals = new Retrievals(apiController);
            String     result     = retrievals.CreateRetrieval(claimId, retrievalCreateRequest);

            //assert
            Assert.That(result, Is.EqualTo("300002296235"));
        }
コード例 #2
0
ファイル: RetrievalsTests.cs プロジェクト: emrahm/MasterCom
        public void CreateRetrieval_Create_GetRequestId()
        {
            //arrange
            String requestId = "300002296235";
            RetrievalCreateRequest retrievalCreateRequest = new RetrievalCreateRequest();

            retrievalCreateRequest.retrievalRequestReason = "6343";
            retrievalCreateRequest.docNeeded = "2";

            apiController.Setup(f => f.Create <RetrievalResponse>(It.IsAny <long>(), It.IsAny <String>(), retrievalCreateRequest))
            .Returns(new RetrievalResponse()
            {
                requestId = requestId
            });

            //act
            Retrievals retrievals = new Retrievals(apiController.Object);
            String     result     = retrievals.CreateRetrieval(0, claimId, retrievalCreateRequest);

            //assert
            Assert.That(result, Is.EqualTo(requestId));
        }