From 41af81f6f86a9a93ab235702315ac2a0200e7707 Mon Sep 17 00:00:00 2001 From: Pascal Birchler Date: Tue, 24 May 2022 00:22:33 +0200 Subject: [PATCH] Media: Enable caption hotlinking by default (#11541) --- includes/Experiments.php | 1 + .../integration/tests/REST_API/Hotlinking_Controller.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/Experiments.php b/includes/Experiments.php index ed898d88a523..8805dc45a41f 100644 --- a/includes/Experiments.php +++ b/includes/Experiments.php @@ -330,6 +330,7 @@ public function get_experiments(): array { 'label' => __( 'Caption hotlinking', 'web-stories' ), 'description' => __( 'Enable hotlinking of captions', 'web-stories' ), 'group' => 'editor', + 'default' => true, ], /** * Author: @spacedmonkey diff --git a/tests/phpunit/integration/tests/REST_API/Hotlinking_Controller.php b/tests/phpunit/integration/tests/REST_API/Hotlinking_Controller.php index 007dc992c356..a5c0c5abeb8f 100644 --- a/tests/phpunit/integration/tests/REST_API/Hotlinking_Controller.php +++ b/tests/phpunit/integration/tests/REST_API/Hotlinking_Controller.php @@ -225,7 +225,7 @@ public function test_get_item_schema(): void { $this->assertArrayHasKey( 'mime_type', $properties ); $this->assertArrayHasKey( 'type', $properties ); $this->assertArrayHasKey( 'enum', $properties['type'] ); - $this->assertEqualSets( [ 'audio', 'image', 'video' ], $properties['type']['enum'] ); + $this->assertEqualSets( [ 'audio', 'image', 'video', 'caption' ], $properties['type']['enum'] ); } /**