Skip to content

Commit c509f67

Browse files
groeckakpm00
authored andcommitted
Revert "list: test: fix tests for list_cut_position()"
This reverts commit e620799. The commit introduces unit test failures. Expected cur == &entries[i], but cur == 0000037fffadfd80 &entries[i] == 0000037fffadfd60 # list_test_list_cut_position: pass:0 fail:1 skip:0 total:1 not ok 21 list_test_list_cut_position # list_test_list_cut_before: EXPECTATION FAILED at lib/list-test.c:444 Expected cur == &entries[i], but cur == 0000037fffa9fd70 &entries[i] == 0000037fffa9fd60 # list_test_list_cut_before: EXPECTATION FAILED at lib/list-test.c:444 Expected cur == &entries[i], but cur == 0000037fffa9fd80 &entries[i] == 0000037fffa9fd70 Revert it. Link: https://lkml.kernel.org/r/[email protected] Fixes: e620799 ("list: test: fix tests for list_cut_position()") Signed-off-by: Guenter Roeck <[email protected]> Cc: I Hsin Cheng <[email protected]> Cc: David Gow <[email protected]> Signed-off-by: Andrew Morton <[email protected]>
1 parent f30beff commit c509f67

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

lib/list-test.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -408,13 +408,10 @@ static void list_test_list_cut_position(struct kunit *test)
408408

409409
KUNIT_EXPECT_EQ(test, i, 2);
410410

411-
i = 0;
412411
list_for_each(cur, &list1) {
413412
KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]);
414413
i++;
415414
}
416-
417-
KUNIT_EXPECT_EQ(test, i, 1);
418415
}
419416

420417
static void list_test_list_cut_before(struct kunit *test)
@@ -439,13 +436,10 @@ static void list_test_list_cut_before(struct kunit *test)
439436

440437
KUNIT_EXPECT_EQ(test, i, 1);
441438

442-
i = 0;
443439
list_for_each(cur, &list1) {
444440
KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]);
445441
i++;
446442
}
447-
448-
KUNIT_EXPECT_EQ(test, i, 2);
449443
}
450444

451445
static void list_test_list_splice(struct kunit *test)

0 commit comments

Comments
 (0)