Rename test methods to test_ to allow collection by pytest
Part of T1261
This commit is contained in:
parent
8f5b10b3a3
commit
b3e815bef8
5 changed files with 5 additions and 26 deletions
|
@ -4,23 +4,19 @@
|
|||
|
||||
import unittest
|
||||
|
||||
from nose.tools import istest
|
||||
|
||||
from swh.lister import utils
|
||||
|
||||
|
||||
class UtilsTest(unittest.TestCase):
|
||||
|
||||
@istest
|
||||
def split_range(self):
|
||||
def test_split_range(self):
|
||||
actual_ranges = list(utils.split_range(14, 5))
|
||||
self.assertEqual(actual_ranges, [(0, 5), (5, 10), (10, 14)])
|
||||
|
||||
actual_ranges = list(utils.split_range(19, 10))
|
||||
self.assertEqual(actual_ranges, [(0, 10), (10, 19)])
|
||||
|
||||
@istest
|
||||
def split_range_errors(self):
|
||||
def test_split_range_errors(self):
|
||||
with self.assertRaises(TypeError):
|
||||
list(utils.split_range(None, 1))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue