<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Guides on Orchard</title><link>https://orchard.pthm.dev/docs/guides/</link><description>Recent content in Guides on Orchard</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://orchard.pthm.dev/docs/guides/index.xml" rel="self" type="application/rss+xml"/><item><title>Seeding a demo environment</title><link>https://orchard.pthm.dev/docs/guides/demo-seeding/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://orchard.pthm.dev/docs/guides/demo-seeding/</guid><description>&lt;h1 id="seeding-a-demo-environment"&gt;Seeding a demo environment&lt;a class="anchor" href="#seeding-a-demo-environment"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;&lt;strong&gt;Goal.&lt;/strong&gt; Produce a database that tells a compelling story when someone opens the
product. Not just rows — a believable narrative: customers with histories, orders
with realistic timing, payments with a mix of outcomes.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Why Orchard.&lt;/strong&gt; Hand-written SQL seed scripts rot. They drift from the schema,
they can&amp;rsquo;t vary the story for different audiences, and they don&amp;rsquo;t compose. A
scenario describes the story once; variables let you reshape it per demo.&lt;/p&gt;</description></item><item><title>Manual UAT testing</title><link>https://orchard.pthm.dev/docs/guides/uat-testing/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://orchard.pthm.dev/docs/guides/uat-testing/</guid><description>&lt;h1 id="manual-uat-testing"&gt;Manual UAT testing&lt;a class="anchor" href="#manual-uat-testing"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;&lt;strong&gt;Goal.&lt;/strong&gt; Reproducible test cases for QA and stakeholders. &amp;ldquo;A subscription with
three failed payments&amp;rdquo; should be one command, not a fifteen-minute click-through.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Why Orchard.&lt;/strong&gt; UAT scripts usually live as a README page of SQL snippets, a
shared Notion doc, or inside someone&amp;rsquo;s head. Turning them into scenarios makes
them runnable, version-controlled, and reviewable.&lt;/p&gt;
&lt;h2 id="pattern-test-case-per-scenario"&gt;Pattern: test case per scenario&lt;a class="anchor" href="#pattern-test-case-per-scenario"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Each distinct UAT case becomes a scenario file. Name them after the test case:&lt;/p&gt;</description></item><item><title>Local development environments</title><link>https://orchard.pthm.dev/docs/guides/local-dev/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://orchard.pthm.dev/docs/guides/local-dev/</guid><description>&lt;h1 id="local-development-environments"&gt;Local development environments&lt;a class="anchor" href="#local-development-environments"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;&lt;strong&gt;Goal.&lt;/strong&gt; New engineers clone the repo, run one command, and have a working local
database with enough data to develop against. No &amp;ldquo;ask Slack for a SQL dump.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Why Orchard.&lt;/strong&gt; A single authoritative scenario replaces the tribal-knowledge
approach. The scenario lives in the repo and evolves with the schema.&lt;/p&gt;
&lt;h2 id="pattern-one-dev-scenario-per-service"&gt;Pattern: one &amp;ldquo;dev&amp;rdquo; scenario per service&lt;a class="anchor" href="#pattern-one-dev-scenario-per-service"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;scenarios/
└── dev.hcl&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;code&gt;dev.hcl&lt;/code&gt; is the canonical &amp;ldquo;everything you need to boot up locally.&amp;rdquo; Engineers
run it after applying migrations.&lt;/p&gt;</description></item><item><title>Integration testing</title><link>https://orchard.pthm.dev/docs/guides/integration-testing/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://orchard.pthm.dev/docs/guides/integration-testing/</guid><description>&lt;h1 id="integration-testing"&gt;Integration testing&lt;a class="anchor" href="#integration-testing"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;&lt;strong&gt;Goal.&lt;/strong&gt; Shared, versioned setup for your integration test suite. Each test
needs a predictable slice of the database; Orchard produces that slice from a
scenario.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Why Orchard.&lt;/strong&gt; Integration tests tend to accumulate setup code in Go/Python/
whatever — &lt;code&gt;createMerchant(t, db, &amp;quot;Acme&amp;quot;)&lt;/code&gt; functions that duplicate what your
product already does. Orchard scenarios are a source of truth that both tests
and local dev can share.&lt;/p&gt;
&lt;h2 id="pattern-scenario-per-test-fixture"&gt;Pattern: scenario per test fixture&lt;a class="anchor" href="#pattern-scenario-per-test-fixture"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;test/
├── integration/
│ ├── fixtures/
│ │ ├── empty.hcl
│ │ ├── one_merchant.hcl
│ │ └── merchant_with_orders.hcl
│ └── ...&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Each test declares which fixture it needs and runs that scenario as part of
setup.&lt;/p&gt;</description></item><item><title>Composing components</title><link>https://orchard.pthm.dev/docs/guides/composing-components/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://orchard.pthm.dev/docs/guides/composing-components/</guid><description>&lt;h1 id="composing-components"&gt;Composing components&lt;a class="anchor" href="#composing-components"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;&lt;strong&gt;Goal.&lt;/strong&gt; Break a large scenario down into reusable components. Think of
components like functions: small, well-named, tested in isolation, reused across
scenarios.&lt;/p&gt;
&lt;h2 id="when-to-extract-a-component"&gt;When to extract a component&lt;a class="anchor" href="#when-to-extract-a-component"&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Extract a component when you notice one of these signals:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Repetition.&lt;/strong&gt; The same 5–10 lines of HCL appear in three scenarios. Make
them a component.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Named concepts.&lt;/strong&gt; When you find yourself wanting to say &lt;em&gt;&amp;ldquo;a merchant&amp;rdquo;&lt;/em&gt;
instead of &lt;em&gt;&amp;ldquo;three SQL inserts and two HTTP calls&amp;rdquo;&lt;/em&gt;, you&amp;rsquo;ve found the
component boundary.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Scope variation.&lt;/strong&gt; A small concept today might need to expand. A component
gives you a single place to change behavior for all callers.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Don&amp;rsquo;t extract:&lt;/p&gt;</description></item></channel></rss>