Code Duplication    Length = 17-18 lines in 3 locations

tests/unit/GigyaTest.php 3 locations

@@ 265-281 (lines=17) @@
262
        static::assertSame($gigyaResponse, $result);
263
    }
264
265
    public function testSettingDataCenterToAuWillCallAuUri()
266
    {
267
        $gigyaResponse = $this->setupCall(
268
            'accounts.getAccountInfo',
269
            'https://accounts.au1.gigya.com/accounts.getAccountInfo',
270
            [
271
                'auth'        => 'gigya',
272
                'verify'      => $this->certPath,
273
                'form_params' => [],
274
            ]
275
        );
276
        $client = $this->createClient('key', 'secret', Gigya::DC_AU);
277
278
        $result = $client->accounts()->getAccountInfo([]);
279
280
        static::assertSame($gigyaResponse, $result);
281
    }
282
283
    public function testSettingDataCenterToUsWillCallUsUri()
284
    {
@@ 283-299 (lines=17) @@
280
        static::assertSame($gigyaResponse, $result);
281
    }
282
283
    public function testSettingDataCenterToUsWillCallUsUri()
284
    {
285
        $gigyaResponse = $this->setupCall(
286
            'accounts.getAccountInfo',
287
            'https://accounts.us1.gigya.com/accounts.getAccountInfo',
288
            [
289
                'auth'        => 'gigya',
290
                'verify'      => $this->certPath,
291
                'form_params' => [],
292
            ]
293
        );
294
        $client = $this->createClient('key', 'secret', Gigya::DC_US);
295
296
        $result = $client->accounts()->getAccountInfo([]);
297
298
        static::assertSame($gigyaResponse, $result);
299
    }
300
301
    public function testSettingTheUserKeyWillPassItThroughToGuzzle()
302
    {
@@ 301-318 (lines=18) @@
298
        static::assertSame($gigyaResponse, $result);
299
    }
300
301
    public function testSettingTheUserKeyWillPassItThroughToGuzzle()
302
    {
303
        $gigyaResponse = $this->setupCall(
304
            'accounts.getAccountInfo',
305
            'https://accounts.eu1.gigya.com/accounts.getAccountInfo',
306
            [
307
                'auth'        => 'gigya',
308
                'verify'      => $this->certPath,
309
                'form_params' => [],
310
            ]
311
        );
312
        $client = $this->createClient('key', 'userSecret', Gigya::DC_EU, 'userKey');
313
        $client->setFactory($this->factory);
314
315
        $result = $client->accounts()->getAccountInfo([]);
316
317
        static::assertSame($gigyaResponse, $result);
318
    }
319
320
    public function testPassingParamsThroughToTheMethodWillPassThroughToGuzzle()
321
    {