withDisabledSecurityPlugin() ->start(); } /** * @throws \JsonException */ public function testOpenSearch(): void { $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, sprintf( 'http://%s:%d', self::$container->getHost(), self::$container->getFirstMappedPort() )); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $response = (string) curl_exec($ch); $this->assertNotEmpty($response); /** @var array{cluster_name: string} $data */ $data = json_decode($response, true, JSON_THROW_ON_ERROR, JSON_THROW_ON_ERROR); $this->assertArrayHasKey('cluster_name', $data); $this->assertEquals('docker-cluster', $data['cluster_name']); } }