Пример #1
0
def setUpModule():
    """called once, before anything else in this module"""
    # pull in test environment as dict
    global TestEnv
    get_test_env(TestEnv)
    # Fake the INSTALL_PREFIX for metadata lookup, this gives
    # './share/mythtv/metadata/Television/ttvdb.py'
    # './share/mythtv/metadata/Movie/tmdb3.py'
    # $ mkdir -p ./share/mythtv/metadata/Television
    # $ mkdir -p ./share/mythtv/metadata/Movie
    # and copy the scripts from
    # mythtv/programs/scripts/metadata/Movie/tmdb3.py
    # mythtv/programs/scripts/metadata/Television/ttvdb.py
    # set the PYTHONPATH
    # export PYTHONPATH=`pwd`

    cwd = os.getcwd()
    rewrt_file = os.path.join(cwd, "MythTV", "static.py")
    org_file   = os.path.join(cwd, "MythTV", "static.org")

    rewrite_static_prefix(rewrt_file, org_file, cwd)

    from MythTV.static import INSTALL_PREFIX

    global INSTALL_PREFIX
Пример #2
0
def setUpModule():
    """called once, before anything else in this module"""
    # pull in test environment as dict
    global TestEnv
    get_test_env(TestEnv)