Code Duplication    Length = 27-27 lines in 2 locations

exercises/dependency-heaven/solution/vendor/danielstjules/stringy/tests/StringyTest.php 2 locations

@@ 1301-1327 (lines=27) @@
1298
        $this->assertEquals($str, $stringy);
1299
    }
1300
1301
    public function truncateProvider()
1302
    {
1303
        return array(
1304
            array('Test foo bar', 'Test foo bar', 12),
1305
            array('Test foo ba', 'Test foo bar', 11),
1306
            array('Test foo', 'Test foo bar', 8),
1307
            array('Test fo', 'Test foo bar', 7),
1308
            array('Test', 'Test foo bar', 4),
1309
            array('Test foo bar', 'Test foo bar', 12, '...'),
1310
            array('Test foo...', 'Test foo bar', 11, '...'),
1311
            array('Test ...', 'Test foo bar', 8, '...'),
1312
            array('Test...', 'Test foo bar', 7, '...'),
1313
            array('T...', 'Test foo bar', 4, '...'),
1314
            array('Test fo....', 'Test foo bar', 11, '....'),
1315
            array('Test fòô bàř', 'Test fòô bàř', 12, '', 'UTF-8'),
1316
            array('Test fòô bà', 'Test fòô bàř', 11, '', 'UTF-8'),
1317
            array('Test fòô', 'Test fòô bàř', 8, '', 'UTF-8'),
1318
            array('Test fò', 'Test fòô bàř', 7, '', 'UTF-8'),
1319
            array('Test', 'Test fòô bàř', 4, '', 'UTF-8'),
1320
            array('Test fòô bàř', 'Test fòô bàř', 12, 'ϰϰ', 'UTF-8'),
1321
            array('Test fòô ϰϰ', 'Test fòô bàř', 11, 'ϰϰ', 'UTF-8'),
1322
            array('Test fϰϰ', 'Test fòô bàř', 8, 'ϰϰ', 'UTF-8'),
1323
            array('Test ϰϰ', 'Test fòô bàř', 7, 'ϰϰ', 'UTF-8'),
1324
            array('Teϰϰ', 'Test fòô bàř', 4, 'ϰϰ', 'UTF-8'),
1325
            array('What are your pl...', 'What are your plans today?', 19, '...')
1326
        );
1327
    }
1328
1329
    /**
1330
     * @dataProvider safeTruncateProvider()
@@ 1342-1368 (lines=27) @@
1339
        $this->assertEquals($str, $stringy);
1340
    }
1341
1342
    public function safeTruncateProvider()
1343
    {
1344
        return array(
1345
            array('Test foo bar', 'Test foo bar', 12),
1346
            array('Test foo', 'Test foo bar', 11),
1347
            array('Test foo', 'Test foo bar', 8),
1348
            array('Test', 'Test foo bar', 7),
1349
            array('Test', 'Test foo bar', 4),
1350
            array('Test foo bar', 'Test foo bar', 12, '...'),
1351
            array('Test foo...', 'Test foo bar', 11, '...'),
1352
            array('Test...', 'Test foo bar', 8, '...'),
1353
            array('Test...', 'Test foo bar', 7, '...'),
1354
            array('...', 'Test foo bar', 4, '...'),
1355
            array('Test....', 'Test foo bar', 11, '....'),
1356
            array('Test fòô bàř', 'Test fòô bàř', 12, '', 'UTF-8'),
1357
            array('Test fòô', 'Test fòô bàř', 11, '', 'UTF-8'),
1358
            array('Test fòô', 'Test fòô bàř', 8, '', 'UTF-8'),
1359
            array('Test', 'Test fòô bàř', 7, '', 'UTF-8'),
1360
            array('Test', 'Test fòô bàř', 4, '', 'UTF-8'),
1361
            array('Test fòô bàř', 'Test fòô bàř', 12, 'ϰϰ', 'UTF-8'),
1362
            array('Test fòôϰϰ', 'Test fòô bàř', 11, 'ϰϰ', 'UTF-8'),
1363
            array('Testϰϰ', 'Test fòô bàř', 8, 'ϰϰ', 'UTF-8'),
1364
            array('Testϰϰ', 'Test fòô bàř', 7, 'ϰϰ', 'UTF-8'),
1365
            array('ϰϰ', 'Test fòô bàř', 4, 'ϰϰ', 'UTF-8'),
1366
            array('What are your plans...', 'What are your plans today?', 22, '...')
1367
        );
1368
    }
1369
1370
    /**
1371
     * @dataProvider reverseProvider()