<?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>DEV Community: David Daly</title>
    <description>The latest articles on DEV Community by David Daly (@ddaly).</description>
    <link>https://dev.to/ddaly</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%2F175413%2Fc770df57-45cd-4488-870f-4a468373da57.png</url>
      <title>DEV Community: David Daly</title>
      <link>https://dev.to/ddaly</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ddaly"/>
    <language>en</language>
    <item>
      <title>How does your team approach unit testing?</title>
      <dc:creator>David Daly</dc:creator>
      <pubDate>Fri, 14 Jun 2019 15:06:44 +0000</pubDate>
      <link>https://dev.to/ddaly/how-does-your-team-approach-unit-testing-1b18</link>
      <guid>https://dev.to/ddaly/how-does-your-team-approach-unit-testing-1b18</guid>
      <description>&lt;p&gt;I work for a large organisation, but a fairly new team. Our tech stack is JavaScript based (Node, Typescript, Angular, AWS Lambda). As a core principle for our team, we strive to always hit 100% unit test coverage in any project we work on. &lt;/p&gt;

&lt;p&gt;While this is generally a great practice to follow, after doing this for multiple projects I can see some downsides to always having to hit 100%. &lt;/p&gt;

&lt;p&gt;Eg:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Having to fully mock certain things (Databases, AWS Services, etc...) just to hit the magic 100% number.&lt;/li&gt;
&lt;li&gt;Sometimes tests are added only to ensure the code is covered, instead of actually being a useful test.&lt;/li&gt;
&lt;li&gt;Having a 100% coverage policy takes a lot of time and effort to do, but doesn't actually ensure the app works end-to-end without also adding E2E tests.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;From experience, I think a middle ground with high test coverage, but also including end-to-end testing seems like a better way to test applications (although this also has challenges).&lt;/p&gt;

&lt;p&gt;I would be interested to hear about other options / opinions here, and if there are other means to ensure test coverage is high, but also functional. &lt;/p&gt;

</description>
      <category>discuss</category>
      <category>testing</category>
      <category>javascript</category>
    </item>
  </channel>
</rss>
