예제 #1
0
def test_wpm_when_starting_up():
    assert _wpm_of_chars(
        _timestamp_items("foooo barr"),
        method="traditional",
    ) == 120
예제 #2
0
def test_wpm_of_chars(time):
    time.return_value = 10
    chars = [("f", 5), ("o", 5), ("o", 5), ("o", 5), ("o", 5)]
    assert _wpm_of_chars(chars, method="traditional") == 12
예제 #3
0
def test_wpm_of_nothing():
    assert _wpm_of_chars(_timestamp_items(""), method="traditional") == 0
def test_wpm_when_starting_up():
    assert _wpm_of_chars(_timestamp_chars("foooo barr")) == 120
def test_wpm_of_chars(time):
    time.return_value = 10
    chars = [("f", 5), ("o", 5), ("o", 5), ("o", 5), ("o", 5)]
    assert _wpm_of_chars(chars) == 12
def test_wpm_of_nothing():
    assert _wpm_of_chars(_timestamp_chars("")) == 0