File tree Expand file tree Collapse file tree 5 files changed +5
-5
lines changed
Expand file tree Collapse file tree 5 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ public function __construct(
3232 /**
3333 * {@inheritdoc}
3434 */
35- public function getWopiClientURL (string $ action = ' view ' , string $ mimetype = 'text/plain ' ): ?string {
35+ public function getWopiClientURL (string $ action , string $ mimetype = 'text/plain ' ): ?string {
3636 $ result = $ this ->parsedXml ->xpath (sprintf (
3737 "/wopi-discovery/net-zone/app[@name='%s']/action[@name='%s'] " ,
3838 $ mimetype ,
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ interface DiscoveryInterface {
3333 * The WOPI client URL, or NULL if none provided for the MIME type and
3434 * operation.
3535 */
36- public function getWopiClientURL (string $ action = ' view ' , string $ mimetype = 'text/plain ' ): ?string ;
36+ public function getWopiClientURL (string $ action , string $ mimetype = 'text/plain ' ): ?string ;
3737
3838 /**
3939 * Gets the public key used for proofing.
Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ public function testFetchClientUrl(): void {
4141 /** @var \Drupal\collabora_online\Discovery\DiscoveryFetcherInterface $discovery_fetcher */
4242 $ discovery_fetcher = \Drupal::service (DiscoveryFetcherInterface::class);
4343 $ discovery = $ discovery_fetcher ->getDiscovery ();
44- $ client_url = $ discovery ->getWopiClientURL ();
44+ $ client_url = $ discovery ->getWopiClientURL (' view ' );
4545 $ this ->assertNotNull ($ client_url );
4646 // The protocol, domain and port are known when this test runs in the
4747 // docker-compose setup.
Original file line number Diff line number Diff line change @@ -117,7 +117,7 @@ public function testGetDiscovery(): void {
117117 $ discovery = $ fetcher ->getDiscovery ();
118118 $ this ->assertSame (
119119 'http://collabora.test:9980/browser/61cf2b4/cool.html? ' ,
120- $ discovery ->getWopiClientURL (),
120+ $ discovery ->getWopiClientURL (' view ' ),
121121 );
122122 $ this ->assertSame (
123123 [
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ public function testWopiClientUrl(): void {
2525 $ discovery = $ this ->getDiscoveryFromFile ($ file );
2626 $ this ->assertSame (
2727 'http://collabora.test:9980/browser/61cf2b4/cool.html? ' ,
28- $ discovery ->getWopiClientURL (),
28+ $ discovery ->getWopiClientURL (' view ' ),
2929 );
3030 $ this ->assertSame (
3131 'http://spreadsheet.collabora.test:9980/browser/61cf2b4/cool.html? ' ,
You can’t perform that action at this time.
0 commit comments