[issue29912] Overlapping tests between list_tests and seq_tests

Jim Fasarakis-Hilliard report at bugs.python.org
Sun Mar 26 19:42:37 EDT 2017


New submission from Jim Fasarakis-Hilliard:

Seems the CommonTests class defined in list_tests duplicates the testing performed by seq_tests.CommonTests in the following functions:

    test_index, test_count

Additionally, a part of test_imul from list_tests.CommonTests can be moved to seq_tests.CommonTests. (specifically, up until `        self.assertEqual(u, self.type2test([]))`).

Am I missing some non-obvious thing here or can I safely remove the two test functions in list_tests.CommonTests and move (while also adding a super call) part of test_imul from list_tests.CommonTests to test_imul in seq_tests.CommonTests?

Some links:

[1a] seq_tests test_index: https://github.com/python/cpython/blob/1e73dbbc29c96d0739ffef92db36f63aa1aa30da/Lib/test/seq_tests.py#L363
[1b] list_tests test_index:
https://github.com/python/cpython/blob/1e73dbbc29c96d0739ffef92db36f63aa1aa30da/Lib/test/list_tests.py#L376

[2a] seq_tests test_count:
https://github.com/python/cpython/blob/1e73dbbc29c96d0739ffef92db36f63aa1aa30da/Lib/test/seq_tests.py#L344
[2b] list_tests test_count:
https://github.com/python/cpython/blob/1e73dbbc29c96d0739ffef92db36f63aa1aa30da/Lib/test/list_tests.py#L357

[3a] seq_tests test_imul:
https://github.com/python/cpython/blob/1e73dbbc29c96d0739ffef92db36f63aa1aa30da/Lib/test/seq_tests.py#L300
[3b] list_tests test_imul:
https://github.com/python/cpython/blob/1e73dbbc29c96d0739ffef92db36f63aa1aa30da/Lib/test/list_tests.py#L550

----------
components: Tests
messages: 290550
nosy: Jim Fasarakis-Hilliard
priority: normal
severity: normal
status: open
title: Overlapping tests between list_tests and seq_tests
type: behavior

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue29912>
_______________________________________


More information about the Python-bugs-list mailing list