How to use the opsdroid.cli.start.configure_lang function in opsdroid

To help you get started, we’ve selected a few opsdroid examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github opsdroid / opsdroid / tests / test_cli.py View on Github external
def setUp(self):
        self._tmp_dir = os.path.join(tempfile.gettempdir(), "opsdroid_tests")
        with contextlib.suppress(FileExistsError):
            os.makedirs(self._tmp_dir, mode=0o777)
        configure_lang({})
github opsdroid / opsdroid / tests / test_connector_websocket.py View on Github external
def setUp(self):
        self.loop = asyncio.new_event_loop()
        configure_lang({})
github opsdroid / opsdroid / tests / test_connector_github.py View on Github external
def setUp(self):
        opsdroid = amock.CoroutineMock()
        configure_lang({})
        self.connector = ConnectorGitHub(
            {"name": "github", "token": "test"}, opsdroid=opsdroid
        )
github opsdroid / opsdroid / tests / test_connector_webexteams.py View on Github external
def setUp(self):
        self.loop = asyncio.new_event_loop()
        configure_lang({})
github opsdroid / opsdroid / tests / test_configuration.py View on Github external
def setup(self):
        configure_lang({})
        opsdroid = mock.MagicMock()
        loader = ld.Loader(opsdroid)
        return opsdroid, loader
github opsdroid / opsdroid / tests / test_connector_gitter.py View on Github external
def setUp(self):
        opsdroid = amock.CoroutineMock()
        configure_lang({})
        self.connector = ConnectorGitter(
            {"bot-name": "github", "room-id": "test-id", "token": "test-token"},
            opsdroid=opsdroid,
        )
        with amock.patch("aiohttp.ClientSession") as mocked_session:
            self.connector.session = mocked_session
github opsdroid / opsdroid / tests / test_loader.py View on Github external
def setup(self):
        configure_lang({})
        opsdroid = mock.MagicMock()
        loader = ld.Loader(opsdroid)
        return opsdroid, loader
github opsdroid / opsdroid / tests / test_connector_rocketchat.py View on Github external
def setUp(self):
        configure_lang({})
        self.connector = RocketChat(
            {
                "name": "rocket.chat",
                "token": "test",
                "user-id": "userID",
                "default_target": "test",
            },
            opsdroid=OpsDroid(),
        )

        self.connector.latest_update = "2018-10-08T12:57:37.126Z"

        with amock.patch("aiohttp.ClientSession") as mocked_session:
            self.connector.session = mocked_session
github opsdroid / opsdroid / tests / test_connector_facebook.py View on Github external
def setUp(self):
        self.loop = asyncio.new_event_loop()
        configure_lang({})
github opsdroid / opsdroid / tests / test_logging.py View on Github external
def setUp(self):
        self._tmp_dir = os.path.join(tempfile.gettempdir(), "opsdroid_tests")
        with contextlib.suppress(FileExistsError):
            os.makedirs(self._tmp_dir, mode=0o777)
        configure_lang({})