<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Omer Morad</title>
    <description>The latest articles on Forem by Omer Morad (@omermorad).</description>
    <link>https://forem.com/omermorad</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F574693%2F86b2f530-544d-4fcf-95de-00502e279be0.png</url>
      <title>Forem: Omer Morad</title>
      <link>https://forem.com/omermorad</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/omermorad"/>
    <language>en</language>
    <item>
      <title>Your AI Agent Should Not Grade Itself: Software Self-Verification Crisis</title>
      <dc:creator>Omer Morad</dc:creator>
      <pubDate>Fri, 15 May 2026 16:14:20 +0000</pubDate>
      <link>https://forem.com/omermorad/your-ai-agent-should-not-grade-itself-software-self-verification-crisis-29en</link>
      <guid>https://forem.com/omermorad/your-ai-agent-should-not-grade-itself-software-self-verification-crisis-29en</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;TL;DR:&lt;/strong&gt; I have been working on &lt;a href="https://github.com/suites-dev/boundary-first-engineering" rel="noopener noreferrer"&gt;Boundary-First Engineering&lt;/a&gt;, a manifesto built around one question: who verifies the code when the AI wrote the checks too? The answer it argues for is boundaries, contracts, and evidence that came from outside the implementation loop. I still want agents writing code. I just do not want them grading the final exam.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I have been spending a lot of time with AI coding agents and one pattern keeps showing up.&lt;/p&gt;

&lt;p&gt;The agent writes the feature, writes the tests, fixes the failures, updates the summary, and hands back a pull request with green checks before my morning espresso is cold.&lt;/p&gt;

&lt;p&gt;It feels good for about five seconds, and then the uncomfortable part arrives: the same loop that produced the code also produced most of the evidence that says the code is correct.&lt;/p&gt;

&lt;p&gt;That pattern is the reason I started writing Boundary-First Engineering, an open manifesto for verifying software in the agentic era. The short version of its thesis is that we moved the bottleneck from writing software to trusting software, and our verification habits have not caught up.&lt;/p&gt;

&lt;h2&gt;
  
  
  How things started to feel off
&lt;/h2&gt;

&lt;p&gt;For years I trusted the usual, classic stack: unit tests, code review, coverage, static analysis, and CI. It was never perfect, but it worked at human speed.&lt;/p&gt;

&lt;p&gt;Tests expressed intent.&lt;br&gt;
Review caught what tests missed.&lt;br&gt;
CI made sure we did not forget the obvious things.&lt;/p&gt;

&lt;p&gt;An agent now compresses all of that into one flow. It generates the implementation, generates tests for it, runs the suite, patches the code, fixes the tests, and explains why everything is fine.&lt;/p&gt;

&lt;p&gt;The green check still looks the same. It does not always mean the same thing.&lt;/p&gt;

&lt;p&gt;A green check used to mean the code passed checks that someone cared enough to define. Now it can mean the code passed checks created by the same process that wrote the code. Those are not the same statement, and the difference is easy to miss because the surface looks identical.&lt;/p&gt;
&lt;h2&gt;
  
  
  The circular validation problem
&lt;/h2&gt;

&lt;p&gt;The concept I want to name is circular validation, which I hear about a lot recently.&lt;/p&gt;

&lt;p&gt;Circular validation is what happens when the same implementation loop produces the code, the tests, the fixes, and the explanation. The work can look disciplined and still be a closed circle of agreement. Nothing in it is fraudulent. It is just self-referential.&lt;/p&gt;

&lt;p&gt;Here is a deliberately boring example, because boring examples are where production bugs actually live:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Ticket: show account data for customers with access

Agent builds:
- GET /accounts/:id
- tests for active customers
- tests for missing accounts
- tests for permission failure

Missed rule:
- suspended accounts must still be visible to compliance users
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The agent did not encode the suspended-account rule because it did not understand it. The generated tests do not catch the omission because they were written from the same understanding that produced the code. Of course it misses. The blind spot is shared by the implementation and the evidence at once.&lt;/p&gt;

&lt;p&gt;This is not a claim that the model is bad. Better models miss the rule less often. They do not remove the structural problem, which is that code and its checks coming from one source share whatever that source did not know.&lt;/p&gt;

&lt;p&gt;So when someone tells me the AI wrote tests too, I do not automatically feel safer. Of course it wrote tests. The more useful question is where those tests came from.&lt;/p&gt;

&lt;p&gt;Coverage measures reach. It does not measure truth. A 90 percent covered misunderstanding is still a misunderstanding.&lt;/p&gt;

&lt;h2&gt;
  
  
  The boundary move
&lt;/h2&gt;

&lt;p&gt;Boundary-First Engineering starts from a simple claim: systems earn trust at their boundaries.&lt;/p&gt;

&lt;p&gt;A boundary can be a:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;HTTP contract&lt;/li&gt;
&lt;li&gt;Database state you own&lt;/li&gt;
&lt;li&gt;Queue message&lt;/li&gt;
&lt;li&gt;Event schema&lt;/li&gt;
&lt;li&gt;Permission decision exposed to another service&lt;/li&gt;
&lt;li&gt;CLI output someone scripts against&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Internals matter. I am not arguing that we delete unit tests and hope for the best. But internals are private and changeable. Boundaries are public, durable, and expensive to get wrong. They are what users, services, and auditors actually experience.&lt;/p&gt;

&lt;p&gt;So in the agentic era verification should start with what crosses the boundary, not with whether the generated internals look reasonable.&lt;/p&gt;

&lt;p&gt;That can be small and practical: an OpenAPI document, a protobuf file, acceptance scenarios written before implementation, a policy rule that runs in CI, a dependency rule that has been enforced for months. The goal is not a large specification nobody reads. It is a thin, durable artifact that the implementation has to satisfy.&lt;/p&gt;

&lt;p&gt;If the spec needs the code beside it to make sense, it is not doing its job.&lt;/p&gt;

&lt;h2&gt;
  
  
  The provenance test
&lt;/h2&gt;

&lt;p&gt;There is one line from the manifesto I keep returning to: the test is provenance, not appearance.&lt;/p&gt;

&lt;p&gt;Appearance is cheap now. A pull request generated by an agent can look serious very quickly. Clear test names, table-driven cases, a confident summary, and a tidy explanation.&lt;/p&gt;

&lt;p&gt;Provenance asks a harder question: did this check originate outside the implementation loop?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Outside&lt;/strong&gt; can mean another team published the contract before the work started. It can mean a product owner wrote acceptance scenarios from user behavior. It can mean compliance defined the data-handling rules, or a consumer service owns the schema.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Inside&lt;/strong&gt; means I wrote the code and then wrote the test for what I wrote. Inside means an agent generated both in one task. Inside means I approved a generated test after reading a generated explanation of generated code.&lt;/p&gt;

&lt;p&gt;Approval is not laundering. A human clicking approve does not change where an artifact came from. Review can accept, reject, or improve evidence. It cannot convert the builder's own evidence into independent evidence by signing off on it.&lt;/p&gt;

&lt;p&gt;This is the part teams will find uncomfortable, because we are used to treating review as the step that makes a change safe enough. At AI speed, human attention is the scarce resource, and spending it to bless evidence from inside the loop is a poor use of it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Fast enough to matter
&lt;/h2&gt;

&lt;p&gt;There is a second constraint that is easy to overlook. Verification has to be fast enough for an agent to use it.&lt;/p&gt;

&lt;p&gt;A boundary check that runs once a week is governance theater. A boundary check that runs in under a second becomes part of how the agent works. It can hit the schema, fail, adjust, hit the contract test, fail, adjust, and converge toward the boundary instead of toward its own explanation.&lt;/p&gt;

&lt;p&gt;This is why the boring guardrails matter more now, not less: types, schemas, linters, architectural dependency rules, generated clients from contracts, database constraints, policy checks, small integration tests against real systems you own.&lt;/p&gt;

&lt;p&gt;Those guardrails need provenance too. A lint rule added in the same branch to make that branch pass is not an independent check. A dependency rule that has protected the architecture for six months is. When implementations become cheap and rotate often, the durable constraints around them are the part worth keeping.&lt;/p&gt;

&lt;p&gt;One scope note: everything above is about pre-merge verification. Production trust still has to accrue at runtime, through telemetry, tracing, and runtime contract checks. That is the other half of the discipline, and the manifesto is explicit that it lives outside its scope.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why I care about this
&lt;/h2&gt;

&lt;p&gt;I have spent a lot of time on testing tools and developer experience. When I built Suites, the motivation was the repetitive, inconsistent experience of unit testing in TypeScript dependency injection codebases. I still think good testing tools matter.&lt;/p&gt;

&lt;p&gt;But working with agents made me aware of a layer that better tooling does not reach. A faster, smoother test-writing experience does not help if the same loop writes the implementation and decides what correct means. Faster testing is good. Faster circular validation is not.&lt;/p&gt;

&lt;p&gt;The habit I think we need is small to describe and harder to practice: before asking whether the generated code looks reasonable, ask what outside artifact it was made to satisfy.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where this stands
&lt;/h2&gt;

&lt;p&gt;Boundary-First Engineering is a short manifesto right now, not a framework and not a product. It argues for a handful of things:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Boundaries over internals&lt;/li&gt;
&lt;li&gt;Real systems over stubs for what you own&lt;/li&gt;
&lt;li&gt;What crosses the boundary over what happens inside it&lt;/li&gt;
&lt;li&gt;Verification from outside the implementation loop over tests written from within it&lt;/li&gt;
&lt;li&gt;Fast guardrails that agents can actually use&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It is early, and I would rather it be argued with than agreed with quietly. If you work with AI agents, backend contracts, testing strategy, CI, or architecture rules, the parts of it that are wrong are most likely wrong in ways you would see first.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The manifesto: &lt;a href="https://github.com/suites-dev/boundary-first-engineering" rel="noopener noreferrer"&gt;Boundary-First Engineering&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;How to sign or propose changes: &lt;a href="https://github.com/suites-dev/boundary-first-engineering/blob/main/CONTRIBUTING.md" rel="noopener noreferrer"&gt;CONTRIBUTING&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If the code can write itself, it is worth asking why we still let it grade itself.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>ai</category>
      <category>software</category>
      <category>testing</category>
    </item>
    <item>
      <title>Unit Test Like a Pro: Automock, My Open Source Answer to Mocking Frustration 🤓💡🎭</title>
      <dc:creator>Omer Morad</dc:creator>
      <pubDate>Tue, 12 Dec 2023 16:16:38 +0000</pubDate>
      <link>https://forem.com/omermorad/unit-test-like-a-pro-automock-my-open-source-answer-to-mocking-frustration-31p4</link>
      <guid>https://forem.com/omermorad/unit-test-like-a-pro-automock-my-open-source-answer-to-mocking-frustration-31p4</guid>
      <description>&lt;p&gt;Hello Dev Community 🙋‍♂️&lt;/p&gt;

&lt;p&gt;I've been working with TypeScript for a while, and one thing that always seems to be a time-consuming task is manually creating mocks for unit tests when using dependency injection frameworks.&lt;/p&gt;

&lt;p&gt;There is often a lack of consistent structure, which can make the experience even more frustrating. It can get repetitive and result in test suites that are difficult to handle and prone to becoming overly complex.&lt;/p&gt;

&lt;p&gt;That's why I created Automock. This project is open-source and seeks to change the way we conduct unit testing in TypeScript DI environments. It automatically creates mock objects for classes, improves testing execution speed, and maintaines a consistent structure within DI frameworks such as NestJS and InversifyJS, as well as popular testing libraries like Jest and Sinon.&lt;/p&gt;

&lt;p&gt;🔗 Here are some links to check out:&lt;br&gt;
😎 GitHub: &lt;a href="https://github.com/automock/automock" rel="noopener noreferrer"&gt;https://github.com/automock/automock&lt;/a&gt;&lt;br&gt;
🐈 Automock's NestJS Official Recipe: &lt;a href="https://docs.nestjs.com/recipes/automock" rel="noopener noreferrer"&gt;https://docs.nestjs.com/recipes/automock&lt;/a&gt;&lt;br&gt;
📦 NPM: &lt;a href="https://www.npmjs.com/package/@automock/jest" rel="noopener noreferrer"&gt;https://www.npmjs.com/package/@automock/jest&lt;/a&gt;&lt;br&gt;
📚 Docs Website: &lt;a href="https://automock.dev" rel="noopener noreferrer"&gt;https://automock.dev&lt;/a&gt;&lt;/p&gt;



&lt;p&gt;The rest of the examples in this post will be based on the following example, which is using NestJS arbitrarily but applies to all DI frameworks:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Injectable&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@nestjs/common&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="p"&gt;@&lt;/span&gt;&lt;span class="nd"&gt;Injectable&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;UserDAL&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="nf"&gt;getUsers&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt; &lt;span class="nb"&gt;Promise&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;User&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="p"&gt;...&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="nf"&gt;getSomethingElse&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt; &lt;span class="nb"&gt;Promise&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;unknown&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="p"&gt;...&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="p"&gt;@&lt;/span&gt;&lt;span class="nd"&gt;Injectable&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;UserApiService&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="nf"&gt;fetchUsers&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt; &lt;span class="nb"&gt;Promise&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;User&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="p"&gt;...&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="nf"&gt;fetchSomethingElse&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt; &lt;span class="nb"&gt;Promise&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;unknown&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="p"&gt;...&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="p"&gt;@&lt;/span&gt;&lt;span class="nd"&gt;Injectable&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;UserService&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="nx"&gt;userDal&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;private&lt;/span&gt; &lt;span class="nx"&gt;userApi&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;UserApiService&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{}&lt;/span&gt;

  &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="nf"&gt;getAllUsers&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt; &lt;span class="nb"&gt;Promise&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;User&lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;fromDb&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;userDal&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getUsers&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;fromApi&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;userApi&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fetchUsers&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;[...&lt;/span&gt;&lt;span class="nx"&gt;fromDb&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;...&lt;/span&gt;&lt;span class="nx"&gt;fromApi&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;UserService&lt;/code&gt; aggregates user data from both a database and an external api. To test the &lt;code&gt;UserService&lt;/code&gt; in isolation, we need to mock the &lt;code&gt;UserDAL&lt;/code&gt; and &lt;code&gt;UserApiService&lt;/code&gt; classes.&lt;/p&gt;

&lt;h2&gt;
  
  
  🔄 Traditional Approach to Unit Testing
&lt;/h2&gt;

&lt;p&gt;Creating manual mocks for class dependencies is a common part of the unit testing process. This manual method is time-consuming and tedious, especially when working with large classes, here is an example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;userDalMock&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;Mocked&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;getUsers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
  &lt;span class="na"&gt;getSomethingElse&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;userApiSvcMock&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;Mocked&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;UserApiService&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;fetchUsers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
  &lt;span class="na"&gt;fetchSomethingElse&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Looks familiar, right? 🥲&lt;/p&gt;

&lt;p&gt;Regardless of the testing technique you use, these mocks are essential for the class under test. In most cases, you can avoid interacting with other classes in two ways:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Inject these mocks as arguments into newly created instances of the classes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Leverage your framework's DI container to replace actual objects with their equivalent mock objects.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The primary goal of both approaches is to separate the unit under test (the class) and subject it to predictable and controlled behavior.&lt;/p&gt;

&lt;p&gt;Here is the traditional approach using NestJS, which appears to be applicable to all dependency injection frameworks and libraries:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="nf"&gt;describe&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;User Service Unit Test&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="na"&gt;userService&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;UserService&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="c1"&gt;// Under Test&lt;/span&gt;

  &lt;span class="c1"&gt;// Mocks Declaration&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="na"&gt;userDal&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;Mocked&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="na"&gt;apiService&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;Mocked&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;ApiService&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="na"&gt;moduleRef&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;TestingModule&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="nf"&gt;beforeAll&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;async &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;moduleRef&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;Test&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;createTestingModule&lt;/span&gt;&lt;span class="p"&gt;({})&lt;/span&gt;
      &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;overrideProvider&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
      &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;useValue&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;userDalMock&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
      &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;overrideProvider&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ApiService&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
      &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;useValue&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;userApiSvcMock&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
      &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;compile&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

    &lt;span class="nx"&gt;apiService&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;moduleRef&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ApiService&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="nx"&gt;userDal&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;moduleRef&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;});&lt;/span&gt;

  &lt;span class="nf"&gt;test&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;should retrieve users&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;async &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="p"&gt;...&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;As we change and refactor the &lt;code&gt;UserService&lt;/code&gt;, it becomes increasingly reliant on additional classes and methods, which can complicate the process of updating these mocks. Furthermore, if there are any modifications to the other classes (&lt;code&gt;UserDAL&lt;/code&gt; and &lt;code&gt;UserApiService&lt;/code&gt;), it will be necessary to also make updates to the stubs.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/3eS7kmMo9Ibzk0F7xg/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/3eS7kmMo9Ibzk0F7xg/giphy.gif" width="480" height="440"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This continual maintenance requirement can lead to a testing environment that is hard and error-prone since devs need to make sure the mocks accurately reflect the current state of the codebase. This adds another layer of complexity to the development process.&lt;/p&gt;

&lt;h2&gt;
  
  
  💪 Automock's Approach
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Automatic Mock Generation
&lt;/h3&gt;

&lt;p&gt;Automock's most notable feature is automated mock generation, which eliminates the repetitive task of manually creating and maintaining mock objects.&lt;/p&gt;

&lt;p&gt;Here is a typical test suite using Automock:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;TestBed&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@automock/jest&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;UserService&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;UserApiService&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;./services&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="nf"&gt;describe&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Users Service Unit Test&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// 🧪 Unit under test&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="na"&gt;userService&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;UserService&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="c1"&gt;// 🎭 Declare Mocks&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="na"&gt;mockUserApiService&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;Mocked&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;UserApiService&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="na"&gt;mockUserDal&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;jest&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;Mocked&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="nf"&gt;beforeAll&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="c1"&gt;// 🚀 Automatically mock every dependency, and create on-the-fly virtual DI container for the mocks&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;unit&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;unitRef&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;TestBed&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;create&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;UserService&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;compile&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

    &lt;span class="c1"&gt;// ⚙️ Assign the unit under test&lt;/span&gt;
    &lt;span class="nx"&gt;userService&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;unit&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="c1"&gt;// 🔍 Retrieve mocks from the unit reference and assign&lt;/span&gt;
    &lt;span class="nx"&gt;mockUserApiService&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;unitRef&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;UserApiService&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="nx"&gt;mockUserDal&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;unitRef&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;UserDAL&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;});&lt;/span&gt;

  &lt;span class="nf"&gt;it&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;should retrieve users from both database and api&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;async &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="c1"&gt;// 📝 Arrange&lt;/span&gt;
    &lt;span class="nx"&gt;mockUserApiService&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;fetchUsers&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;mockResolvedValue&lt;/span&gt;&lt;span class="p"&gt;([{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Joe&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="p"&gt;}]);&lt;/span&gt;
    &lt;span class="nx"&gt;mockUserDal&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;getUsers&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;mockResolvedValue&lt;/span&gt;&lt;span class="p"&gt;([{&lt;/span&gt; &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Jane&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="p"&gt;}]);&lt;/span&gt;

    &lt;span class="c1"&gt;// 🎬 Act&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;users&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;userService&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getAllUsers&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

    &lt;span class="c1"&gt;// ✅ Assert&lt;/span&gt;
    &lt;span class="nf"&gt;expect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;users&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;toHaveLength&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

    &lt;span class="nf"&gt;expect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;mockUserApiService&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;fetchUsers&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;toHaveBeenCalled&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="nf"&gt;expect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;mockUserDal&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;getUsers&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;toHaveBeenCalled&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="p"&gt;});&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;📚 &lt;a href="https://automock.dev/docs/getting-started/examples" rel="noopener noreferrer"&gt;Full Step-by-Step Example&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;This ensures consistent structure and syntax within test suites. This consistency is crucial and is maintained even as underlying classes or methods undergo changes or refactoring, providing a stable and reliable testing environment.&lt;/strong&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Speed
&lt;/h3&gt;

&lt;p&gt;The introduction of a virtual DI container, using the &lt;code&gt;TestBed&lt;/code&gt;, is another key aspect. It speeds up the testing execution by bypassing the conventional DI framework loading, leading to much faster test execution.&lt;/p&gt;

&lt;p&gt;The isolation provided in testing ensures that each test runs independently with its own set of automatically provided mock implementations, creating a streamlined and interference-free environment.&lt;/p&gt;

&lt;p&gt;🔗 Check out the full benchmark:&lt;br&gt;
GitHub: &lt;a href="https://github.com/automock/benchmark#visualizations" rel="noopener noreferrer"&gt;https://github.com/automock/benchmark#visualizations&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;code&gt;tsc&lt;/code&gt; demonstrated a significant 28.9% improvement in speed for Automock (vs NestJS). Similarly, &lt;code&gt;tsc-isolated&lt;/code&gt; and &lt;code&gt;SWC&lt;/code&gt; also exhibited notable increases of 26.0% and 23.2% respectively. &lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;em&gt;* I haven't had the opportunity to test it with other dependency injection frameworks rather then NestJS yet.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/3ornk4kGAQDeMaPBqo/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/3ornk4kGAQDeMaPBqo/giphy.gif" width="480" height="264"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  🧠🤓 The Reason Behind It All
&lt;/h2&gt;

&lt;p&gt;I was motivated to create this project because I faced many common challenges when working with unit testing in different dependency injection frameworks. Regardless of the framework used, the process always proved to be complex and time-consuming. This problem was not limited to my personal experience; it highlighted a wider gap that exists throughout the industry.&lt;/p&gt;

&lt;p&gt;I have a clear vision for Automock - to make the testing experience more efficient and improve the reliability and quality of code. This project represents a significant stride towards enhancing development practices within the TypeScript community, making them more efficient and effective.&lt;/p&gt;

&lt;h2&gt;
  
  
  👀 How Things Stand Right Now, and What Am I Looking for?
&lt;/h2&gt;

&lt;p&gt;Until now, the project has gained around 60K monthly downloads, thanks to the recognition of NestJS, which added Automock to their recipes section.&lt;/p&gt;

&lt;p&gt;Currently, the project is in its early-middle stage. It supports NestJS and InversifyJS. I am looking to expand its capabilities and integrate DI frameworks, and &lt;strong&gt;I'm seeking contributions from the developer community, especially those proficient in TypeScript, dependency injection, and unit testing methodologies.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  It's for You ❤️
&lt;/h2&gt;

&lt;p&gt;Automock is more than just a tool; it is intended to be a community-driven solution aimed at aiding developers facing similar challenges in unit testing.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://i.giphy.com/media/kesLaG9wgJCbmv1YfT/giphy.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://i.giphy.com/media/kesLaG9wgJCbmv1YfT/giphy.gif" width="480" height="196"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I invite you to be part of this journey, let's shape the future of software quality and unit testing!&lt;/p&gt;

&lt;p&gt;Happy testing! 🚀🧪🤓&lt;/p&gt;

</description>
      <category>programming</category>
      <category>opensource</category>
      <category>typescript</category>
      <category>backend</category>
    </item>
  </channel>
</rss>
