Exemple #1
0
 internal static void ValidateGetCredentialsResponse
 (
     GetCredentialsRequest aGetCredentialsRequest,
     GetCredentialsResponse aGetCredentialsResponse
 )
 {
     aGetCredentialsResponse.CorrelationId.Should().Be(aGetCredentialsRequest.CorrelationId);
     aGetCredentialsResponse.CredentialRecords.Should().NotBeNull();
     aGetCredentialsResponse.CredentialRecords.Count.Should().Be(1);
 }
        public void Constructor_InitializesProperties(
            MessageResponseCode responseCode,
            string username,
            string password)
        {
            var response = new GetCredentialsResponse(responseCode, username, password);

            Assert.Equal(responseCode, response.ResponseCode);
            Assert.Equal(username, response.Username);
            Assert.Equal(password, response.Password);
        }
        public void JsonSerialization_ReturnsCorrectJson(
            MessageResponseCode responseCode,
            string username,
            string password,
            string expectedJson)
        {
            var response = new GetCredentialsResponse(responseCode, username, password);

            var actualJson = TestUtilities.Serialize(response);

            Assert.Equal(expectedJson, actualJson);
        }
Exemple #4
0
        public async Task GetCredentialsResponse()
        {
            GetCredentialsResponse GetCredentialsResponse = await Send(GetCredentialsRequest);

            ValidateGetCredentialsResponse(GetCredentialsRequest, GetCredentialsResponse);
        }