11<?php
22
3- use Openapi \OpenapiOauthClient ;
3+ use Openapi \OauthClient ;
44use PHPUnit \Framework \TestCase ;
55
6- final class OpenapiOauthClientTest extends TestCase
6+ final class OauthClientTest extends TestCase
77{
88 private string $ username = 'test_username ' ;
99 private string $ apikey = 'test_apikey ' ;
1010
1111 public function testOauthClientCreation (): void
1212 {
13- $ client = new OpenapiOauthClient ($ this ->username , $ this ->apikey , true );
14- $ this ->assertInstanceOf (OpenapiOauthClient ::class, $ client );
13+ $ client = new OauthClient ($ this ->username , $ this ->apikey , true );
14+ $ this ->assertInstanceOf (OauthClient ::class, $ client );
1515 }
1616
1717 public function testOauthClientCanBeCreatedFromEnvironmentVariables (): void
@@ -24,14 +24,14 @@ public function testOauthClientCanBeCreatedFromEnvironmentVariables(): void
2424 $ this ->assertNotSame ('' , $ username , 'OPENAPI_USERNAME is empty ' );
2525 $ this ->assertNotSame ('' , $ apikey , 'OPENAPI_SANDBOX_KEY is empty ' );
2626
27- $ client = new OpenapiOauthClient ($ username , $ apikey , true );
28- $ this ->assertInstanceOf (OpenapiOauthClient ::class, $ client );
27+ $ client = new OauthClient ($ username , $ apikey , true );
28+ $ this ->assertInstanceOf (OauthClient ::class, $ client );
2929 }
3030
3131 public function testOauthClientProductionMode (): void
3232 {
33- $ client = new OpenapiOauthClient ($ this ->username , $ this ->apikey , false );
34- $ this ->assertInstanceOf (OpenapiOauthClient ::class, $ client );
33+ $ client = new OauthClient ($ this ->username , $ this ->apikey , false );
34+ $ this ->assertInstanceOf (OauthClient ::class, $ client );
3535 }
3636
3737 public function testEnvironmentVariablesAreAvailable (): void
@@ -47,7 +47,7 @@ public function testCreateTokenWithScopes(): void
4747 {
4848 $ this ->markTestSkipped ('Requires valid credentials for integration test ' );
4949
50- $ client = new OpenapiOauthClient ($ this ->username , $ this ->apikey , true );
50+ $ client = new OauthClient ($ this ->username , $ this ->apikey , true );
5151 $ scopes = [
5252 'GET:test.imprese.openapi.it/advance ' ,
5353 'POST:test.postontarget.com/fields/country '
0 commit comments