Coverage for tests/conftest.py: 100%
12 statements
« prev ^ index » next coverage.py v7.6.1, created at 2024-11-30 23:17 +0000
« prev ^ index » next coverage.py v7.6.1, created at 2024-11-30 23:17 +0000
1import sys
2import os
3from pathlib import Path
5# Agregar la ruta del directorio raíz del proyecto al sys.path
6sys.path.insert(0, str(Path(__file__).resolve().parent.parent))
8from app import app
12import pytest
13from app import app
15@pytest.fixture
16def client():
17 with app.test_client() as client:
18 with app.app_context():
19 yield client