def _setup():
    global magic, spark_controller, shell, ipython_display

    conf.override_all({})

    shell = MagicMock()
    ipython_display = MagicMock()
    magic = RemoteSparkMagics(shell=None)
    magic.shell = shell
    magic.ipython_display = ipython_display

    spark_controller = MagicMock()
    magic.spark_controller = spark_controller
def test_get_livy_kind_covers_all_langs():
    for lang in Constants.lang_supported:
        RemoteSparkMagics._get_livy_kind(lang)