<aside>
</aside>
μ΅μ’ νλ‘μ νΈ κ΅¬μ‘°:
graph TD
A(my-pytest-project) --> FOLDER_GITHUB(.github);
FOLDER_GITHUB --> FOLDER_WORKFLOWS(workflows);
FOLDER_WORKFLOWS --> FILE_CI_YML(ci.yml);
A --> B(.venv);
A --> C(mycalc);
A --> D(tests);
A --> E(pytest.ini);
A --> F(noxfile.py λͺ¨λ μλν μμ
μ μ);
A --> G(requirements-dev.txt);
A --> H(pyproject.toml ν¨ν€μ§,λꡬ μ€μ );
A --> I(dist λΉλ κ²°κ³Όλ¬Ό ν΄λ μλ μμ±);
C --> C1(__init__.py);
C --> C2(calculator.py);
C --> C3(exchange.py);
D --> D1(__init__.py);
D --> D2(test_calculator.py Pytest κΈ°λ₯ μμ );
D --> D3(conftest.py 곡μ ν½μ€μ²);
D --> D4(test_scopes.py μ€μ½ν μμ );
D --> D5(test_markers.py λ§μ»€ μμ );
D --> D6(test_exchange.py Mock μμ );
D --> D7(test_properties.py Hypothesis μμ );
D --> D8(test_calculator_unittest.py unittest μμ );
style FOLDER_GITHUB fill:#ddd
style FILE_CI_YML fill:#ddf
style F fill:#ffc
style H fill:#eef
style I fill:#ddd, stroke-dasharray: 5 5
ν΅μ¬ νμΌ λ¦¬λ·°:
mycalc/
: ν
μ€νΈ λ° ν¨ν€μ§ λμ μμ€ μ½λ (Calculator
ν΄λμ€ λ±).tests/
: λ€μν Pytest κΈ°λ₯(ν½μ€μ², νλΌλ―Έν°ν, λ§μ»€, Mock, Hypothesis) νμ© ν
μ€νΈ μ½λ. conftest.py
(곡μ ν½μ€μ²).noxfile.py
: μλν νλΈ. tests
, lint
, format
, build
, release
λ± λ€μν Nox μΈμ
Python μ½λλ‘ μ μ. κ° μΈμ
μ 격리 νκ²½μμ μμ‘΄μ± μ€μΉ λ° λͺ
λ Ήμ΄ μ€ν.pyproject.toml
: νλ‘μ νΈ λ©νλ°μ΄ν°, λΉλ μμ€ν
μ 보, μ½λ νμ§ λꡬ(Black, isort λ±) μ€μ .requirements-dev.txt
: κ°λ°/ν
μ€νΈ/μλν μμ
νμ λͺ¨λ Python ν¨ν€μ§ μμ‘΄μ± λͺ©λ‘. Nox μΈμ
μμ νμ©..github/workflows/ci.yml
: GitHub Actions CI μ€μ . μ½λ push/PR μ μλ Nox μΈμ
μ€ν (νμ§/ν
μ€νΈ κ²μ¦).