コード例 #1
0
 public void GetStreetTeam_UriNotValid_ArgumentException()
 {
     //Arrange
     var validPath = "/test/";
     Mock<AccessTokenManagerBaseStub> tokenManager = new Mock<AccessTokenManagerBaseStub>();
     StreetTeamEndpoint streetTeamRequest = new StreetTeamEndpoint(tokenManager.Object, new UsersModel { Team = validPath });
     //Act and Assert
     Assert.Throws(typeof(ArgumentException), () => { streetTeamRequest.GetStreetTeam("Not validPath."); });
 }
コード例 #2
0
 public void GetStreetTeam_UriValid_DoesNotThrowArgumentException()
 {
     //Arrange
     var validPath = "/test/";
     Mock<AccessTokenManagerBaseStub> tokenManager = new Mock<AccessTokenManagerBaseStub>();
     StreetTeamEndpoint streetTeamRequest = new StreetTeamEndpoint(tokenManager.Object, new UsersModel { Team = validPath });
     //Act and Assert
     Assert.DoesNotThrow(() => { streetTeamRequest.GetStreetTeam(validPath); });
 }