{"library":"pytest-archon","title":"pytest-archon","description":"pytest-archon is a pytest plugin for enforcing architectural boundaries in Python projects. It allows you to define rules that prevent certain imports between modules, ensuring layering and dependency direction. Current version: 0.0.7. Release cadence: infrequent, no set schedule.","language":"python","status":"active","last_verified":"Fri May 01","install":{"commands":["pip install pytest-archon"],"cli":null},"imports":["from pytest_archon import archrule","from pytest_archon import archrule"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import pytest\nfrom pytest_archon import archrule\n\ndef test_import_rule():\n    (\n        archrule(\"myapp.services\")\n        .should_not_import(\"myapp.ui\")\n        .should_not_import(\"myapp.db\")\n        .check(\"myapp\")\n    )","lang":"python","description":"Define an architecture rule that prevents the 'services' package from importing 'ui' or 'db' packages in the 'myapp' project.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}