Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 627cc7e

Browse filesBrowse files
committed
Display debug info
1 parent 3e90720 commit 627cc7e
Copy full SHA for 627cc7e

File tree

3 files changed

+13
-9
lines changed
Filter options

3 files changed

+13
-9
lines changed

‎.github/workflows/tests.yml

Copy file name to clipboardExpand all lines: .github/workflows/tests.yml
+6-6Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,17 +93,12 @@ jobs:
9393

9494
- name: Install system dependencies
9595
run: |
96-
echo "::group::add apt sources"
97-
sudo wget -O - http://packages.couchbase.com/ubuntu/couchbase.key | sudo apt-key add -
98-
echo "deb http://packages.couchbase.com/ubuntu bionic bionic/main" | sudo tee /etc/apt/sources.list.d/couchbase.list
99-
echo "::endgroup::"
100-
10196
echo "::group::apt-get update"
10297
sudo apt-get update
10398
echo "::endgroup::"
10499
105100
echo "::group::install tools & libraries"
106-
sudo apt-get install libcouchbase-dev librdkafka-dev
101+
sudo apt-get install librdkafka-dev
107102
echo "::endgroup::"
108103
109104
- name: Configure Couchbase
@@ -122,6 +117,11 @@ jobs:
122117
php-version: "${{ matrix.php }}"
123118
tools: pecl
124119

120+
- name: Display versions
121+
run: |
122+
php -r 'foreach (get_loaded_extensions() as $extension) echo $extension . " " . phpversion($extension) . PHP_EOL;'
123+
php -i
124+
125125
- name: Load fixtures
126126
uses: docker://bitnami/openldap
127127
with:

‎src/Symfony/Component/Cache/Adapter/CouchbaseBucketAdapter.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Cache/Adapter/CouchbaseBucketAdapter.php
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class CouchbaseBucketAdapter extends AbstractAdapter
4242
public function __construct(\CouchbaseBucket $bucket, string $namespace = '', int $defaultLifetime = 0, MarshallerInterface $marshaller = null)
4343
{
4444
if (!static::isSupported()) {
45-
throw new CacheException('Couchbase >= 2.6.0 is required.');
45+
throw new CacheException('Couchbase >= 2.6.0 < 3.0.0 is required.');
4646
}
4747

4848
$this->maxIdLength = static::MAX_KEY_LENGTH;
@@ -66,7 +66,7 @@ public static function createConnection($servers, array $options = []): \Couchba
6666
}
6767

6868
if (!static::isSupported()) {
69-
throw new CacheException('Couchbase >= 2.6.0 is required.');
69+
throw new CacheException('Couchbase >= 2.6.0 < 3.0.0 is required.');
7070
}
7171

7272
set_error_handler(function ($type, $msg, $file, $line) { throw new \ErrorException($msg, 0, $type, $file, $line); });
@@ -125,7 +125,7 @@ public static function createConnection($servers, array $options = []): \Couchba
125125

126126
public static function isSupported(): bool
127127
{
128-
return \extension_loaded('couchbase') && version_compare(phpversion('couchbase'), '2.6.0', '>=');
128+
return \extension_loaded('couchbase') && version_compare(phpversion('couchbase'), '2.6.0', '>=') && version_compare(phpversion('couchbase'), '3.0', '<');
129129
}
130130

131131
private static function getOptions(string $options): array

‎src/Symfony/Component/Cache/Tests/Adapter/CouchbaseBucketAdapterTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Cache/Tests/Adapter/CouchbaseBucketAdapterTest.php
+4Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ class CouchbaseBucketAdapterTest extends AdapterTestCase
3232

3333
public static function setupBeforeClass(): void
3434
{
35+
if(!CouchbaseBucketAdapter::isSupported()) {
36+
self::markTestSkipped('Couchbase >= 2.6.0 < 3.0.0 is required.');
37+
}
38+
3539
self::$client = AbstractAdapter::createConnection('couchbase://'.getenv('COUCHBASE_HOST').'/cache',
3640
['username' => getenv('COUCHBASE_USER'), 'password' => getenv('COUCHBASE_PASS')]
3741
);

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.