Basho\Tests\HllOperationsTest::setUpBeforeClass PHP Method

setUpBeforeClass() public static method

public static setUpBeforeClass ( )
    public static function setUpBeforeClass()
    {
        parent::setUpBeforeClass();
        // make completely random key based on time
        static::$key = md5(rand(0, 99) . time());
        try {
            // Skip this suite if the "hlls" bucket type is not present
            $command = (new Command\Builder\FetchBucketProperties(static::$riak))->buildBucket('test', static::HLL_BUCKET_TYPE)->build();
            $response = $command->execute();
            if (!$response->isSuccess() || $response->getCode() != 200) {
                throw new \PHPUnit_Framework_SkippedTestSuiteError("hlls bucket type is not enabled and activated, skipping");
            }
        } catch (\Exception $ex) {
            throw new \PHPUnit_Framework_SkippedTestSuiteError("hlls bucket type is not enabled and activated, skipping");
        }
    }