public function testGet_databox_metadatas() { $request = new Request([], [], [], [], [], ['HTTP_Accept' => 'application/json']); foreach (self::$DI['app']['phraseanet.appbox']->get_databoxes() as $databox) { $result = $this->object->get_databox_metadatas($request, $databox->get_sbas_id()); $this->assertEquals(200, $result->get_http_code()); $this->assertEquals('application/json', $result->get_content_type()); $this->assertTrue(is_array(json_decode($result->format(), true))); } }