def _func_or_print(result, func):
    if func is not None:
        func(result)
    else:
        print(result)
Create a :class:`spotify.Session` mock for testing.
dataset/ETHPy150Open christabor/MoAL/MOAL/helpers/display.py/_func_or_print--crossover with--dataset/ETHPy150Open mopidy/pyspotify/tests/__init__.py/create_session_mock