Exemplo n.º 1
0
def test_config_split_feeds_format_and_template(bot):
    feeds = [
        '#channel2' + rss.CONFIG_SEPARATOR + 'feed2' + rss.CONFIG_SEPARATOR +
        FEED_VALID + rss.CONFIG_SEPARATOR + 'f=fy+fty;t=t|+++{}+++'
    ]
    rss._config_split_feeds(bot, feeds)
    result = rss._feed_exists(bot, 'feed2')
    assert True == result
Exemplo n.º 2
0
def test_config_split_feeds_invalid(bot):
    feeds = [
        '#channel2' + rss.CONFIG_SEPARATOR + 'feed2' + rss.CONFIG_SEPARATOR +
        FEED_INVALID + rss.CONFIG_SEPARATOR + 'f=fy+fty'
    ]
    rss._config_split_feeds(bot, feeds)
    result = rss._feed_exists(bot, 'feed2')
    assert False == result
Exemplo n.º 3
0
def test_config_split_feeds_format_and_template(bot):
    feeds = [
        "#channel2"
        + rss.CONFIG_SEPARATOR
        + "feed2"
        + rss.CONFIG_SEPARATOR
        + FEED_VALID
        + rss.CONFIG_SEPARATOR
        + "f=fy+fty;t=t|+++{}+++"
    ]
    rss._config_split_feeds(bot, feeds)
    result = rss._feed_exists(bot, "feed2")
    assert True == result
Exemplo n.º 4
0
def test_config_split_feeds_invalid(bot):
    feeds = [
        "#channel2"
        + rss.CONFIG_SEPARATOR
        + "feed2"
        + rss.CONFIG_SEPARATOR
        + FEED_INVALID
        + rss.CONFIG_SEPARATOR
        + "f=fy+fty"
    ]
    rss._config_split_feeds(bot, feeds)
    result = rss._feed_exists(bot, "feed2")
    assert False == result