Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit096b42d

Browse files
Guikingonenicolas-grekas
authored andcommitted
Add tests
1 parent3603343 commit096b42d

File tree

4 files changed

+700
-1
lines changed

4 files changed

+700
-1
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?php
2+
3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <fabien@symfony.com>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
12+
namespaceSymfony\Component\HttpClient\Tests;
13+
14+
useSymfony\Component\HttpClient\ApiClient;
15+
useSymfony\Component\HttpClient\CurlHttpClient;
16+
useSymfony\Contracts\HttpClient\ApiClientInterface;
17+
useSymfony\Contracts\HttpClient\Test\ApiClientTestCase;
18+
19+
/**
20+
* @requires extension curl
21+
*/
22+
class CurlApiClientTestextends ApiClientTestCase
23+
{
24+
protectedfunctiongetApiClient():ApiClientInterface
25+
{
26+
returnnewApiClient(newCurlHttpClient());
27+
}
28+
}
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<?php
2+
3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <fabien@symfony.com>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
12+
namespaceSymfony\Component\HttpClient\Tests;
13+
14+
useSymfony\Component\HttpClient\ApiClient;
15+
useSymfony\Component\HttpClient\NativeHttpClient;
16+
useSymfony\Contracts\HttpClient\ApiClientInterface;
17+
useSymfony\Contracts\HttpClient\Test\ApiClientTestCase;
18+
19+
class NativeApiClientTestextends ApiClientTestCase
20+
{
21+
protectedfunctiongetApiClient():ApiClientInterface
22+
{
23+
returnnewApiClient(newNativeHttpClient());
24+
}
25+
}

‎src/Symfony/Contracts/HttpClient/ApiClientInterface.php‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
namespaceSymfony\Contracts\HttpClient;
1313

1414
useSymfony\Contracts\HttpClient\Exception\TransportExceptionInterface;
15-
useSymfony\Contracts\Tests\HttpClient\ApiClientTest;
15+
useSymfony\Contracts\HttpClient\Test\ApiClientTestCase;
1616

1717
/**
1818
* Provides flexible methods for interacting with HTTP APIs.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp