public function testGetToken() { $provider = new \Cloudberry\Provider(API_USERNAME, API_PASSWORD); $token = $provider->getToken(); $this->assertInstanceOf('stdClass', $token); $this->assertNotEmpty($token->access_token); }
public function testListUsers() { $provider = new \Cloudberry\Provider(API_USERNAME, API_PASSWORD); $token = $provider->getToken(); $this->assertInstanceOf('stdClass', $token); $this->assertNotEmpty($token->access_token); $u = new \Cloudberry\Users($token->access_token); $users = $u->getUsers(); $this->assertInternalType('array', $users); }
public function testListPackages() { $provider = new \Cloudberry\Provider(API_USERNAME, API_PASSWORD); $token = $provider->getToken(); $this->assertInstanceOf('stdClass', $token); $this->assertNotEmpty($token->access_token); $d = new \Cloudberry\Destinations($token->access_token); $destinations = $d->getDestinations(); $this->assertInternalType('array', $destinations); }