File: conftest.py

package info (click to toggle)
python-dotenv 1.0.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 260 kB
  • sloc: python: 1,457; makefile: 52
file content (16 lines) | stat: -rw-r--r-- 279 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import pytest
from click.testing import CliRunner


@pytest.fixture
def cli():
    runner = CliRunner()
    with runner.isolated_filesystem():
        yield runner


@pytest.fixture
def dotenv_path(tmp_path):
    path = tmp_path / '.env'
    path.write_bytes(b'')
    yield path