From 7776977378de920205b8356d0143073b176edc70 Mon Sep 17 00:00:00 2001 From: Gabriel Luiz Freitas Almeida Date: Mon, 7 Aug 2023 09:43:37 -0300 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=A7=20chore(conftest.py):=20add=20runn?= =?UTF-8?q?er=20fixture=20to=20enable=20CLI=20testing=20=F0=9F=94=A7=20cho?= =?UTF-8?q?re(conftest.py):=20import=20CliRunner=20from=20typer.testing=20?= =?UTF-8?q?to=20enable=20CLI=20testing=20=F0=9F=94=A7=20chore(conftest.py)?= =?UTF-8?q?:=20remove=20unused=20imports=20and=20blank=20lines=20for=20cod?= =?UTF-8?q?e=20cleanliness?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/conftest.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/conftest.py b/tests/conftest.py index a97270c7c..2eae791cd 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -10,6 +10,7 @@ from fastapi.testclient import TestClient from httpx import AsyncClient from sqlmodel import SQLModel, Session, create_engine from sqlmodel.pool import StaticPool +from typer.testing import CliRunner if TYPE_CHECKING: from langflow.services.database.base import DatabaseManager @@ -149,3 +150,8 @@ def session_getter_fixture(client): yield session yield blank_session_getter + + +@pytest.fixture +def runner(): + return CliRunner()