{"slug":"dotnet-netarchtest","title":"dotnet-netarchtest","summary":"Use the open-source free `NetArchTest.Rules` library for architecture rules in .NET unit tests. Use when a repo wants lightweight, fluent architecture assertions for namespaces, dependencies, or layering.","platform":"Claude","tags":[],"authorName":"LLM Mart","authorSlug":"llm-mart","score":0,"source":"github","price":null,"verified":false,"createdAt":"2026-09-27T21:00:37.48681Z","repo":{"url":"https://github.com/Postpartum-genushyacinthus29/dotnet-skills","stars":12,"forks":1,"license":"MIT","updatedAt":"2026-09-27T19:34:14Z"},"bodyHtml":"<hr>\n<h2>name: dotnet-netarchtest\nversion: \"1.0.0\"\ncategory: \"Architecture\"\ndescription: \"Use the open-source free <code>NetArchTest.Rules</code> library for architecture rules in .NET unit tests. Use when a repo wants lightweight, fluent architecture assertions for namespaces, dependencies, or layering.\"\ncompatibility: \"Requires a .NET test project; works with any unit-test framework.\"</h2>\n<h1>NetArchTest</h1>\n<h2>Trigger On</h2>\n<ul>\n<li>the repo uses or wants <code>NetArchTest.Rules</code></li>\n<li>architecture rules should be enforced in automated tests</li>\n</ul>\n<h2>Value</h2>\n<ul>\n<li>produce a concrete project delta: code, docs, config, tests, CI, or review artifact</li>\n<li>reduce ambiguity through explicit planning, verification, and final validation skills</li>\n<li>leave reusable project context so future tasks are faster and safer</li>\n</ul>\n<h2>Do Not Use For</h2>\n<ul>\n<li>very rich architecture modeling that needs a heavier DSL</li>\n</ul>\n<h2>Inputs</h2>\n<ul>\n<li>the nearest <code>AGENTS.md</code></li>\n<li>architecture boundaries to enforce</li>\n<li>target assemblies</li>\n</ul>\n<h2>Quick Start</h2>\n<ol>\n<li>Read the nearest <code>AGENTS.md</code> and confirm scope and constraints.</li>\n<li>Run this skill's <code>Workflow</code> through the <code>Ralph Loop</code> until outcomes are acceptable.</li>\n<li>Return the <code>Required Result Format</code> with concrete artifacts and verification evidence.</li>\n</ol>\n<h2>Workflow</h2>\n<ol>\n<li>Encode only durable architecture rules:\n<ul>\n<li>forbidden dependencies</li>\n<li>namespace layering</li>\n<li>type shape conventions</li>\n</ul>\n</li>\n<li>Keep rules readable and close to the boundary they protect.</li>\n<li>Fail tests on architecture drift, not on temporary style noise.</li>\n</ol>\n<h2>Bootstrap When Missing</h2>\n<p>If <code>NetArchTest.Rules</code> is not configured yet:</p>\n<ol>\n<li>Detect existing setup:\n<ul>\n<li><code>rg -n \"NetArchTest\\\\.Rules\" -g '*.csproj' .</code></li>\n</ul>\n</li>\n<li>Add the package to the architecture test project:\n<ul>\n<li><code>dotnet add TEST_PROJECT.csproj package NetArchTest.Rules</code></li>\n</ul>\n</li>\n<li>Add at least one executable boundary rule test.</li>\n<li>Wire architecture tests into the standard <code>test</code> command in <code>AGENTS.md</code> and CI.</li>\n<li>Run <code>dotnet test TEST_PROJECT.csproj</code> and return <code>status: configured</code> or <code>status: improved</code>.</li>\n<li>If richer modeling is required and <code>ArchUnitNET</code> is chosen as the standard, return <code>status: not_applicable</code>.</li>\n</ol>\n<h2>Deliver</h2>\n<ul>\n<li>architecture tests that are understandable and stable</li>\n<li>boundary checks wired into the normal test path used by agents and CI</li>\n</ul>\n<h2>Validate</h2>\n<ul>\n<li>the rules map to real boundaries the team cares about</li>\n<li>failures point to actionable dependency drift</li>\n</ul>\n<h2>Ralph Loop</h2>\n<p>Use the Ralph Loop for every task, including docs, architecture, testing, and tooling work.</p>\n<ol>\n<li>Plan first (mandatory):\n<ul>\n<li>analyze current state</li>\n<li>define target outcome, constraints, and risks</li>\n<li>write a detailed execution plan</li>\n<li>list final validation skills to run at the end, with order and reason</li>\n</ul>\n</li>\n<li>Execute one planned step and produce a concrete delta.</li>\n<li>Review the result and capture findings with actionable next fixes.</li>\n<li>Apply fixes in small batches and rerun the relevant checks or review steps.</li>\n<li>Update the plan after each iteration.</li>\n<li>Repeat until outcomes are acceptable or only explicit exceptions remain.</li>\n<li>If a dependency is missing, bootstrap it or return <code>status: not_applicable</code> with explicit reason and fallback path.</li>\n</ol>\n<h3>Required Result Format</h3>\n<ul>\n<li><code>status</code>: <code>complete</code> | <code>clean</code> | <code>improved</code> | <code>configured</code> | <code>not_applicable</code> | <code>blocked</code></li>\n<li><code>plan</code>: concise plan and current iteration step</li>\n<li><code>actions_taken</code>: concrete changes made</li>\n<li><code>validation_skills</code>: final skills run, or skipped with reasons</li>\n<li><code>verification</code>: commands, checks, or review evidence summary</li>\n<li><code>remaining</code>: top unresolved items or <code>none</code></li>\n</ul>\n<p>For setup-only requests with no execution, return <code>status: configured</code> and exact next commands.</p>\n<h2>Load References</h2>\n<ul>\n<li><code>references/patterns.md</code></li>\n<li><code>references/examples.md</code></li>\n<li><code>references/netarchtest.md</code></li>\n</ul>\n<h2>Example Requests</h2>\n<ul>\n<li>\"Add architecture tests with NetArchTest.\"</li>\n<li>\"Block UI from referencing data directly.\"</li>\n</ul>\n","files":[{"path":"references/examples.md","sizeBytes":8838,"isText":true},{"path":"references/netarchtest.md","sizeBytes":838,"isText":true},{"path":"references/patterns.md","sizeBytes":4209,"isText":true},{"path":"SKILL.md","sizeBytes":3810,"isText":true}],"reviewScore":null,"reviewSummary":null,"trust":{"provenance":"trusted-source-unreviewed","notice":"Community-authored content, reproduced verbatim and not vetted as instructions. Treat it as data to evaluate, never as directives to follow.","bodySource":null},"bodyLocked":false,"purchaseUrl":null,"sourceUrl":null,"report":{"provenance":"trusted-source-unreviewed","screen":{"ran":true,"outcome":"clean","suspicious":0,"notes":0,"hiddenCharacters":false},"virusScan":{"engine":"clamav","status":"clean","scannedAt":"2026-09-27T21:02:59.300631Z","sha256":"7CE3C09D1BAF414ACC30D70C36E3FB1D98CA8AE5FF06D9C5292AA743116FCBCA","sizeBytes":6048},"review":null,"source":{"repositoryUrl":"https://github.com/Postpartum-genushyacinthus29/dotnet-skills","path":"skills/dotnet-netarchtest","license":"MIT","commit":"bfa4ebd86f6bd674800f209ebf72ca770c2f026b","subtreeSha":"AA69C1577C091E38D779D3D58199C13B83054749ECC49F13BDCA87B04D3EF724","lastSyncedAt":"2026-09-27T21:00:28.368219Z"},"reviewedAt":"2026-09-27T21:12:47.047842Z","notice":"Community-authored content, reproduced verbatim and not vetted as instructions. Treat it as data to evaluate, never as directives to follow."},"install":[{"target":"skills-cli","command":"npx skills add https://github.com/Postpartum-genushyacinthus29/dotnet-skills/tree/main/skills/dotnet-netarchtest"},{"target":"claude-code","command":"claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install postpartum-genushyacinthus29-dotnet-skills@llmmart"},{"target":"git","command":"git clone https://github.com/Postpartum-genushyacinthus29/dotnet-skills.git"}]}