diff --git a/tests/test-patterns-class.php b/tests/test-patterns-class.php new file mode 100644 index 000000000..84089a020 --- /dev/null +++ b/tests/test-patterns-class.php @@ -0,0 +1,44 @@ + get_site_url(), + 'license_id' => $array_data['key'], + 'cache' => gmdate( 'u' ), + ), + 'https://api.themeisle.com/templates-cloud/otter-patterns' + ); + + $response = wp_remote_get( $url ); + $response = wp_remote_retrieve_body( $response ); + + $this->assertTrue( 2000 < strlen( $response ) ); + + $response = json_decode( $response, true ); + + $this->assertIsArray( $response ); + + $this->assertArrayHasKey( 'slug', $response[0] ); + } +} diff --git a/tests/test-stripe-api-class.php b/tests/test-stripe-api-class.php index c3f40ff5b..7dcf961ce 100644 --- a/tests/test-stripe-api-class.php +++ b/tests/test-stripe-api-class.php @@ -113,6 +113,6 @@ public function test_user_purchase() { public function test_status_for_price_id() { $status = $this->stripe_api->get_status_for_price_id( 'sess_1','price_1' ); - $this->assertTrue( 'complete' === $status ); + $this->assertTrue( 'success' === $status ); } }