Code Duplication    Length = 15-16 lines in 3 locations

tests/phpunit/tests/query/conditionals.php 2 locations

@@ 1246-1260 (lines=15) @@
1243
    /**
1244
     * @ticket 35902
1245
     */
1246
    public function test_is_author_should_not_match_numeric_id_to_nickname_beginning_with_id() 
1247
    {
1248
        $u1 = self::factory()->user->create(
1249
            array(
1250
            'nickname' => 'Foo',
1251
            'user_nicename' => 'foo',
1252
            ) 
1253
        );
1254
        $u2 = self::factory()->user->create(
1255
            array(
1256
            'nickname' => "$u1 Foo",
1257
            'user_nicename' => 'foo-2',
1258
            ) 
1259
        );
1260
1261
        $this->go_to(get_author_posts_url($u2));
1262
1263
        $this->assertTrue(is_author($u2));
@@ 1270-1284 (lines=15) @@
1267
    /**
1268
     * @ticket 35902
1269
     */
1270
    public function test_is_author_should_not_match_numeric_id_to_user_nicename_beginning_with_id() 
1271
    {
1272
        $u1 = self::factory()->user->create(
1273
            array(
1274
            'nickname' => 'Foo',
1275
            'user_nicename' => 'foo',
1276
            ) 
1277
        );
1278
        $u2 = self::factory()->user->create(
1279
            array(
1280
            'nickname' => 'Foo',
1281
            'user_nicename' => "$u1-foo",
1282
            ) 
1283
        );
1284
1285
        $this->go_to(get_author_posts_url($u2));
1286
1287
        $this->assertTrue(is_author($u2));

tests/phpunit/tests/user/multisite.php 1 location

@@ 206-221 (lines=16) @@
203
         /**
204
     * @ticket 23192
205
     */
206
        function test_is_user_spammy() 
207
        {
208
            $user_id = self::factory()->user->create(
209
                array(
210
                'role' => 'author',
211
                'user_login' => 'testuser1',
212
                ) 
213
            );
214
215
            $spam_username = (string) $user_id;
216
            $spam_user_id = self::factory()->user->create(
217
                array(
218
                'role' => 'author',
219
                'user_login' => $spam_username,
220
                ) 
221
            );
222
            update_user_status($spam_user_id, 'spam', '1');
223
224
            $this->assertTrue(is_user_spammy($spam_username));