Ejemplo n.º 1
0
 public void StoreTokenRequestAndSetTransferDestinationsTest()
 {
     using (Tokenio.Tpp.TokenClient tokenClient = TestUtil.CreateClient())
     {
         TppMember payee     = tokenClient.CreateMemberBlocking(TestUtil.RandomAlias());
         string    requestId = StoreAndRetrieveTokenRequestSample
                               .StoreTransferTokenRequestWithDestinationsCallback(
             payee,
             setTransferDestinationsUrl);
         StoreAndRetrieveTokenRequestSample.SetTokenRequestTransferDestinations(
             payee,
             requestId,
             tokenClient,
             setTransferDestinationsCallback);
         TokenRequest request = tokenClient.RetrieveTokenRequestBlocking(requestId);
         Assert.NotNull(request);
         Assert.NotEqual(0, request
                         .GetTokenRequestPayload()
                         .TransferBody
                         .Instructions
                         .TransferDestinations.Count);
         Assert.True(request
                     .GetTokenRequestPayload()
                     .TransferBody
                     .Instructions
                     .TransferDestinations[0].FasterPayments != null);
     }
 }
Ejemplo n.º 2
0
 public void StoreAndRetrieveAccessTokenTest()
 {
     using (Tokenio.Tpp.TokenClient tokenClient = TestUtil.CreateClient())
     {
         TppMember    grantee   = tokenClient.CreateMemberBlocking(TestUtil.RandomAlias());
         string       requestId = StoreAndRetrieveTokenRequestSample.StoreTransferTokenRequest(grantee);
         TokenRequest request   = tokenClient.RetrieveTokenRequestBlocking(requestId);
         Assert.NotNull(request);
     }
 }