Beispiel #1
0
def test_mult_left_without_args(bot, update):
    mult_left(bot, update, [])

    msg = get_sent_message(bot)
    assert "2X left: " in msg
Beispiel #2
0
def test_schedule_without_args(bot, update):
    schedule(bot, update, [])
    msg = get_sent_message(bot)

    assert "Next matches:" in msg
Beispiel #3
0
def test_mult_left_with_args(bot, update):
    mult_left(bot, update, ['tharun'])

    msg = get_sent_message(bot)
    assert int(msg) >= 0
Beispiel #4
0
def test_schedule_with_number(bot, update):
    schedule(bot, update, ['6'])
    msg = get_sent_message(bot)

    assert "Next 6 matches:" in msg
Beispiel #5
0
def test_schedule_with_team(bot, update):
    schedule(bot, update, ['sh'])
    msg = get_sent_message(bot)

    assert "Next sunrisers-hyderabad matches:" in msg
def test_stats_of_handler_without_args(bot, update):
    stats_of(bot, update, [])
    assert "Usage" in get_sent_message(bot)
def test_stats_of_handler_with_args(bot, update):
    stats_of(bot, update, ['shakib'])
    assert "Player - Shakib" in get_sent_message(bot)
def test_points_of_handler_with_args(bot, update):
    points_of(bot, update, ['shakib'])
    assert "Points not" in get_sent_message(bot)
Beispiel #9
0
def test_players_of(bot, update):
    players_of(bot, update, ['sujith'])
    assert "(PP)" in get_sent_message(bot)
Beispiel #10
0
def test_next_in(bot, update):
    next_opportunities(bot, update, ['kohli'])

    msg = get_sent_message(bot)
    assert len(msg) > 2
    assert "date" in msg
def test_points_of_handler_without_args(bot, update):
    points_of(bot, update, [])
    assert "------------" in get_sent_message(bot)
Beispiel #12
0
def test_toss(bot, update):
    toss(bot, update)

    msg = get_sent_message(bot)
    assert msg
Beispiel #13
0
def test_mom(bot, update):
    mom(bot, update)

    msg = get_sent_message(bot)
    assert msg
Beispiel #14
0
def test_points_of_handler_with_args(bot, update):
    subs_left(bot, update, [])
    assert "Matches left" in get_sent_message(bot)
Beispiel #15
0
def test_top_picks_handler_with_args(bot, update):
    top_picks(bot, update, ['mi'])
    assert "Hardik" in get_sent_message(bot)
Beispiel #16
0
def test_top_picks_handler_without_args(bot, update):
    top_picks(bot, update, [])
    assert "Narine" in get_sent_message(bot)