public void Setup() { // Arrange _factory = new TestObjectFactory(); _authenticatedRequestFactory = new AuthenticatedRequestFactory("test_app_key", "test_app_id", "test_app_secret"); _requestParameters = _factory.Create("Test Property 1", 2, true); _requestBody = _factory.Create("Test Property 4", 5, false); }
public async void then_the_get_request_should_be_made_with_a_valid_resource() { var factory = new AuthenticatedRequestFactory(Config.AppKey, Config.AppId, Config.AppSecret); var request = factory.Build(PusherMethod.GET, "/channels/newRestClient"); var client = new PusherRestClient("http://api.pusherapp.com", "pusher-http-dotnet", Version.Parse("4.0.0")); var response = await client.ExecuteGetAsync <TestOccupied>(request); Assert.IsNotNull(response); Assert.IsFalse(response.Data.Occupied); }