# -*- coding: utf-8 -*-
from homehub_backend.app import settings
from homehub_backend.lib import application


class Test_HomeHubApplication:
    def test_init(self):
        # When
        result = application.HomeHubApplication(settings)

        # Then
        assert result['SETTINGS'] == settings

    def test_get_jsonrpc_view(self):
        # Given
        homehub_application = application.HomeHubApplication(settings)

        # When
        result = homehub_application.get_jsonrpc_view()

        # Then
        assert isinstance(result, application.HomeHubJSONRPCView)
