From e92fe3fd78503322cfd3078bad5cbeb7a44eb14d Mon Sep 17 00:00:00 2001 From: Andreas Braun Date: Mon, 17 Jul 2023 14:04:24 +0200 Subject: [PATCH 1/2] Skip queryable encryption tests on standalone servers --- tests/ExamplesTest.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/ExamplesTest.php b/tests/ExamplesTest.php index b3eda5fe6..da58cb055 100644 --- a/tests/ExamplesTest.php +++ b/tests/ExamplesTest.php @@ -360,6 +360,10 @@ public function testQueryableEncryptionExamples(string $file, string $expectedOu $this->skipIfServerVersion('<', '7.0.0', 'Queryable encryption tests require MongoDB 7.0 or later'); + if ($this->isStandalone()) { + $this->markTestSkipped('Encrypted collections are not supported on standalone'); + } + /* Ensure that the key vault, collection under test, and any metadata * collections are cleaned up before and after the example is run. */ $this->dropCollection('test', 'coll', ['encryptedFields' => []]); From 2c35055660621fe39b06c9467a84550ba1867205 Mon Sep 17 00:00:00 2001 From: Andreas Braun Date: Wed, 19 Jul 2023 20:33:40 +0200 Subject: [PATCH 2/2] Use consistent skip message for QE tests Co-authored-by: Jeremy Mikola --- tests/ExamplesTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/ExamplesTest.php b/tests/ExamplesTest.php index da58cb055..2d4a55301 100644 --- a/tests/ExamplesTest.php +++ b/tests/ExamplesTest.php @@ -361,7 +361,7 @@ public function testQueryableEncryptionExamples(string $file, string $expectedOu $this->skipIfServerVersion('<', '7.0.0', 'Queryable encryption tests require MongoDB 7.0 or later'); if ($this->isStandalone()) { - $this->markTestSkipped('Encrypted collections are not supported on standalone'); + $this->markTestSkipped('Queryable encryption requires replica sets'); } /* Ensure that the key vault, collection under test, and any metadata