diff options
author | Roeland Jago Douma <rullzer@users.noreply.github.com> | 2019-08-11 22:46:01 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-11 22:46:01 +0200 |
commit | f465f9d4b9753687f59c09c6ce73c45fb5f79339 (patch) | |
tree | dbd29e6106d0b31cb6f90bda50862ec44ff9f32c /tests | |
parent | 9d6eb2daf7c0f9d50aca78db02dbe8418a642768 (diff) | |
parent | edf946dfc7c8ddc5f4ad125d2a0c780bbc63e769 (diff) | |
download | nextcloud-server-f465f9d4b9753687f59c09c6ce73c45fb5f79339.tar.gz nextcloud-server-f465f9d4b9753687f59c09c6ce73c45fb5f79339.zip |
Merge pull request #16721 from nextcloud/fix/16644
Correctly handle emtpy string in proxyuserpwd config
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/Http/Client/ClientTest.php | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/tests/lib/Http/Client/ClientTest.php b/tests/lib/Http/Client/ClientTest.php index f43958ab865..7a25acd9a50 100644 --- a/tests/lib/Http/Client/ClientTest.php +++ b/tests/lib/Http/Client/ClientTest.php @@ -70,12 +70,22 @@ class ClientTest extends \Test\TestCase { $this->config ->expects($this->at(0)) ->method('getSystemValue') - ->with('proxy', null) + ->with( + $this->equalTo('proxy'), + $this->callback(function ($input) { + return $input === ''; + }) + ) ->willReturn('foo'); $this->config ->expects($this->at(1)) ->method('getSystemValue') - ->with('proxyuserpwd', null) + ->with( + $this->equalTo('proxyuserpwd'), + $this->callback(function ($input) { + return $input === ''; + }) + ) ->willReturn('username:password'); $this->assertSame('username:password@foo', self::invokePrivate($this->client, 'getProxyUri')); } |