public void GetProfilesByNameAddress_ValidNA_ProfilesReturned() { //Arrange NameAddress nameAddress = new NameAddress { AddressLine = "129 West 81st Street", FirstName = "Jerry", LastName = "Seinfeld", City = "New York", State = "NY" }; string jsonProfiles = Properties.Resources.JsonProfiles; Mock<IHttpTransport> httpTransportMock = new Mock<IHttpTransport>(MockBehavior.Strict); httpTransportMock.Setup(httpTransport => httpTransport.Request(It.IsAny<string>(), It.IsAny<ContentType>(), It.IsIn("GET", "POST"), null, null)) .Returns(jsonProfiles); //Action NextCallerClient client = new NextCallerClient(httpTransportMock.Object); string profiles = client.GetByNameAddressJson(nameAddress); //Assert httpTransportMock.Verify(httpTransport => httpTransport.Request(It.IsAny<string>(), It.IsAny<ContentType>(), It.IsIn("GET", "POST"), null, null), Times.Once); Assert.IsNotNull(profiles); Assert.AreEqual(jsonProfiles, profiles); }