def test_quicks_int_input(): assert qs.quicks([ 51, 26, 478, 5, ]) == [5, 26, 51, 478] assert qs.quicks([ 56, 415, 54, 33, ]) == [33, 54, 56, 415]
def main(): num, test = cmd() num = qsort.checkitem(num) if test: pytest.main(['-v', 'functional\\tests.py']) if num: print(qsort.quicks(num))
def test_quicks_empty(): assert qs.quicks([]) == []
def test_quicks_sing_num(): assert qs.quicks([17]) == [17]
def test_quicks_mixed(): assert qs.quicks([-35, 64, 13.67, 31, -76]) == [-76, -35, 13.67, 31, 64]
def test_quicks_error_string(): assert qs.quicks(['like', 'I', 'trains']) == ['I', 'like', 'trains']
def test_quicks_negatives(): assert qs.quicks([-14, -35, -650]) == [-650, -35, -14] assert qs.quicks([-46, -64, -7]) == [-64, -46, -7]
def test_quicks_float_input(): assert qs.quicks([54.52, 54.65, 12.56]) == [12.56, 54.52, 54.65] assert qs.quicks([65.21, 89.54, 21.63]) == [21.63, 65.21, 89.54]