| @@ 339-351 (lines=13) @@ | ||
| 336 | } |
|
| 337 | } |
|
| 338 | ||
| 339 | public function testFlexibleClientShouldBePrivateByDefault(): void |
|
| 340 | { |
|
| 341 | $this->load([ |
|
| 342 | 'clients' => [ |
|
| 343 | 'acme' => [ |
|
| 344 | 'flexible_client' => true, |
|
| 345 | ], |
|
| 346 | ], |
|
| 347 | ]); |
|
| 348 | ||
| 349 | $this->assertContainerBuilderHasService('httplug.client.acme'); |
|
| 350 | $this->assertFalse($this->container->getDefinition('httplug.client.acme.flexible')->isPublic()); |
|
| 351 | } |
|
| 352 | ||
| 353 | public function testHttpMethodsClientShouldBePrivateByDefault(): void |
|
| 354 | { |
|
| @@ 353-365 (lines=13) @@ | ||
| 350 | $this->assertFalse($this->container->getDefinition('httplug.client.acme.flexible')->isPublic()); |
|
| 351 | } |
|
| 352 | ||
| 353 | public function testHttpMethodsClientShouldBePrivateByDefault(): void |
|
| 354 | { |
|
| 355 | $this->load([ |
|
| 356 | 'clients' => [ |
|
| 357 | 'acme' => [ |
|
| 358 | 'http_methods_client' => true, |
|
| 359 | ], |
|
| 360 | ], |
|
| 361 | ]); |
|
| 362 | ||
| 363 | $this->assertContainerBuilderHasService('httplug.client.acme'); |
|
| 364 | $this->assertFalse($this->container->getDefinition('httplug.client.acme.http_methods')->isPublic()); |
|
| 365 | } |
|
| 366 | ||
| 367 | public function testBatchClientShouldBePrivateByDefault(): void |
|
| 368 | { |
|
| @@ 367-379 (lines=13) @@ | ||
| 364 | $this->assertFalse($this->container->getDefinition('httplug.client.acme.http_methods')->isPublic()); |
|
| 365 | } |
|
| 366 | ||
| 367 | public function testBatchClientShouldBePrivateByDefault(): void |
|
| 368 | { |
|
| 369 | $this->load([ |
|
| 370 | 'clients' => [ |
|
| 371 | 'acme' => [ |
|
| 372 | 'batch_client' => true, |
|
| 373 | ], |
|
| 374 | ], |
|
| 375 | ]); |
|
| 376 | ||
| 377 | $this->assertContainerBuilderHasService('httplug.client.acme'); |
|
| 378 | $this->assertFalse($this->container->getDefinition('httplug.client.acme.batch_client')->isPublic()); |
|
| 379 | } |
|
| 380 | ||
| 381 | public function testClientCanBePublic(): void |
|
| 382 | { |
|