# Path: pyfibot/modules/module_urltitle.py
# TITLE_LAG_MAXIMUM = 10
# CACHE_ENABLED = True
#         CACHE_ENABLED = not CACHE_ENABLED
# def init(botref):
# def __get_bs(bot, url):
# def __get_title_tag(url):
# def __get_length_str(secs):
# def __get_age_str(published, use_fresh=True):
# def __get_views(views):
# def __escaped_fragment(url, meta=False):
# def command_cache(bot, user, channel, args):
# def handle_url(bot, user, channel, url, msg):
# def _check_redundant(url, title):
# def _levenshtein_distance(s, t):
# def _title(bot, channel, title, smart=False, prefix=None, url=None):
# def _parse_tweet_from_src(url):
# def _handle_mobile_tweet(url):
# def _handle_tweet2(url):
# def _handle_tweet(url):
#     def twit_timestr(dt):
# def _handle_youtube_shorturl(url):
# def _handle_youtube_gdata(url):
# def _handle_ircquotes(url):
# def _handle_alko2(url):
# def _handle_alko(url):
# def _handle_vimeo(url):
# def _handle_stackoverflow(url):
# def _handle_reddit(url):
# def _handle_areena(url):
#     def _parse_publication_events(data):
#     def get_duration(event):
#     def get_episode(identifier):
#     def get_series(identifier):
# def _handle_wikipedia(url):
#     def clean_page_name(url):
#     def get_content(url):
# def _handle_imgur(url):
#     def create_title(data):
# def _handle_dailymotion(url):
# def _handle_ebay(url):
# def _handle_ebay_no_prefix(url):
# def _handle_ebay_cgi(url):
# def _handle_dealextreme(url):
# def _handle_dealextreme_www(url):
# def fetch_nettiX(url, fields_to_fetch):
# def _handle_nettiauto(url):
# def _handle_nettivene(url):
# def _handle_nettimoto(url):
# def _handle_nettikaravaani(url):
# def _handle_nettivaraosa(url):
# def _handle_nettikone(url):
# def _handle_hitbox(url):
# def _handle_steamstore(url):
# def _handle_discogs(url):
# def _handle_gfycat(url):


from nose.tools import eq_
from pyfibot.modules import module_urltitle
from vcr import VCR
import bot_mock
import pytest
# -*- coding: utf-8 -*-


my_vcr = VCR(
    path_transformer=VCR.ensure_suffix(".yaml"),
    cassette_library_dir="tests/cassettes/",
    record_mode=pytest.config.getoption("--vcrmode"),
)


@pytest.fixture
def botmock():
    bot = bot_mock.BotMock()

# Path: pyfibot/modules/module_urltitle.py
# TITLE_LAG_MAXIMUM = 10
# CACHE_ENABLED = True
#         CACHE_ENABLED = not CACHE_ENABLED
# def init(botref):
# def __get_bs(bot, url):
# def __get_title_tag(url):
# def __get_length_str(secs):
# def __get_age_str(published, use_fresh=True):
# def __get_views(views):
# def __escaped_fragment(url, meta=False):
# def command_cache(bot, user, channel, args):
# def handle_url(bot, user, channel, url, msg):
# def _check_redundant(url, title):
# def _levenshtein_distance(s, t):
# def _title(bot, channel, title, smart=False, prefix=None, url=None):
# def _parse_tweet_from_src(url):
# def _handle_mobile_tweet(url):
# def _handle_tweet2(url):
# def _handle_tweet(url):
#     def twit_timestr(dt):
# def _handle_youtube_shorturl(url):
# def _handle_youtube_gdata(url):
# def _handle_ircquotes(url):
# def _handle_alko2(url):
# def _handle_alko(url):
# def _handle_vimeo(url):
# def _handle_stackoverflow(url):
# def _handle_reddit(url):
# def _handle_areena(url):
#     def _parse_publication_events(data):
#     def get_duration(event):
#     def get_episode(identifier):
#     def get_series(identifier):
# def _handle_wikipedia(url):
#     def clean_page_name(url):
#     def get_content(url):
# def _handle_imgur(url):
#     def create_title(data):
# def _handle_dailymotion(url):
# def _handle_ebay(url):
# def _handle_ebay_no_prefix(url):
# def _handle_ebay_cgi(url):
# def _handle_dealextreme(url):
# def _handle_dealextreme_www(url):
# def fetch_nettiX(url, fields_to_fetch):
# def _handle_nettiauto(url):
# def _handle_nettivene(url):
# def _handle_nettimoto(url):
# def _handle_nettikaravaani(url):
# def _handle_nettivaraosa(url):
# def _handle_nettikone(url):
# def _handle_hitbox(url):
# def _handle_steamstore(url):
# def _handle_discogs(url):
# def _handle_gfycat(url):


# Path: tests/test_wikipedia.py
from nose.tools import eq_
from pyfibot.modules import module_urltitle
from vcr import VCR
import bot_mock
import pytest

# -*- coding: utf-8 -*-


my_vcr = VCR(
    path_transformer=VCR.ensure_suffix(".yaml"),
    cassette_library_dir="tests/cassettes/",
    record_mode=pytest.config.getoption("--vcrmode"),
)


@pytest.fixture
def botmock():
    bot = bot_mock.BotMock()

    module_urltitle.init(bot)