You are here

class TestBynderApi in Bynder 4.0.x

Test Bynder implementation to mock getAssetBankManager().

Hierarchy

Expanded class hierarchy of TestBynderApi

File

tests/src/Unit/BynderApiUnitTest.php, line 90

Namespace

Drupal\Tests\bynder\Unit
View source
class TestBynderApi extends BynderApi {

  /**
   * {@inheritdoc}
   */
  public function getAssetBankManager() {

    // @todo Support updating the token.
    throw new \Exception();
  }

}

Members

Namesort descending Modifiers Type Description Overrides
BynderApi::$bynderApi protected property Bynder Api instance.
BynderApi::$bynderConfig protected property Bynder configuration.
BynderApi::$bynderConfiguration protected property The configuration object.
BynderApi::$cache protected property The cache service.
BynderApi::$configFactory protected property The configuration factory.
BynderApi::$loggerFactory protected property The logger factory.
BynderApi::$session protected property The active session.
BynderApi::$state protected property The state service.
BynderApi::$time protected property The time service.
BynderApi::addAssetUsage public function Creates an asset usage entry in Bynder. Overrides BynderApiInterface::addAssetUsage 1
BynderApi::AUTO_UPDATED_TAGS_QUERIES constant List of getTags queries that are automatically updated in crons.
BynderApi::BYNDER_INTEGRATION_ID constant The Bynder integration ID. 1
BynderApi::CACHED_CALLS constant List of API calls that should be cache with their cache keys as values.
BynderApi::CID_DERIVATIVES constant Cache ID used to store the derivatives information.
BynderApi::CID_METAPROPERTIES constant Cache ID used to store the metaproperties information.
BynderApi::CID_TAGS constant Cache ID used to store the tags information.
BynderApi::finishOAuthTokenRetrieval public function Finishes the access token retrieval after the user has been redirected. Overrides BynderApiInterface::finishOAuthTokenRetrieval
BynderApi::getAssetUsages public function Retrieves all asset usage for a specific asset. Overrides BynderApiInterface::getAssetUsages 1
BynderApi::getCallback protected function
BynderApi::getIntegrationId public function 1
BynderApi::getOauthConfiguration protected function
BynderApi::getTags public function Wraps getTags() and makes sure results are cached properly. 1
BynderApi::hasAccessToken public function Gets if the current user has a valid oAuth access token. Overrides BynderApiInterface::hasAccessToken 1
BynderApi::hasUploadPermissions public function Checks if the current user has upload permissions. Overrides BynderApiInterface::hasUploadPermissions 1
BynderApi::initiateOAuthTokenRetrieval public function Initiates the access token retrieval. Overrides BynderApiInterface::initiateOAuthTokenRetrieval
BynderApi::removeAssetUsage public function Removes asset usage entry for a specific Bynder asset. Overrides BynderApiInterface::removeAssetUsage 1
BynderApi::setBynderConfiguration public function Sets the Bynder configuration. Overrides BynderApiInterface::setBynderConfiguration
BynderApi::updateCachedData public function 1
BynderApi::__call public function
BynderApi::__construct public function BynderApi constructor.
TestBynderApi::getAssetBankManager public function Gets an instance of the asset bank manager to use for DAM queries. Overrides BynderApi::getAssetBankManager