コード例 #1
0
def test_is_strictly_increasing_1():
    """Checking monotonic sequence should return True."""
    assert logfile_check.is_strictly_increasing([0, 100, 200])
コード例 #2
0
def test_is_strictly_increasing_6():
    """Checking a sequence of two items in reverse order should return False."""
    assert not logfile_check.is_strictly_increasing([2500, 2100])
コード例 #3
0
def test_is_strictly_increasing_5():
    """Checking a sequence of two items that are not 100 different should return False."""
    assert not logfile_check.is_strictly_increasing([500, 2100])
コード例 #4
0
def test_is_strictly_increasing_4():
    """Checking a sequence of one item should return True."""
    assert logfile_check.is_strictly_increasing([500])
コード例 #5
0
def test_is_strictly_increasing_3():
    """Checking an empty sequence should return True."""
    assert logfile_check.is_strictly_increasing(None)
コード例 #6
0
def test_is_strictly_increasing_2():
    """Checking non-monotonic sequence should return False."""
    assert not logfile_check.is_strictly_increasing([0, 200, 1000])