<?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: Jack-DO</title>
    <description>The latest articles on Forem by Jack-DO (@jackdo).</description>
    <link>https://forem.com/jackdo</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%2F209717%2F63478040-cbc5-4190-8fe7-dbd65ee3eeb5.png</url>
      <title>Forem: Jack-DO</title>
      <link>https://forem.com/jackdo</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/jackdo"/>
    <language>en</language>
    <item>
      <title>Be an Otter</title>
      <dc:creator>Jack-DO</dc:creator>
      <pubDate>Fri, 06 Sep 2019 19:58:19 +0000</pubDate>
      <link>https://forem.com/dealeron/be-an-otter-209k</link>
      <guid>https://forem.com/dealeron/be-an-otter-209k</guid>
      <description>&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F8m9zawbq76nqjsyozoen.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F8m9zawbq76nqjsyozoen.jpg" alt="River Otter"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A developer can take many approaches to one’s job.  They can float along lazily using just enough effort to keep their head above water, or they can latch onto what is already known and stay adrift for a time.  There’s plenty of ways to be, but the way I want to talk about is &lt;strong&gt;being like an otter&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Otters are quick, nimble, and seemingly fun loving.  Always looking forward to their next challenge -- they approach life eagerly and with a playful mindset.  Naturally inquisitive, they investigate solutions to solve problems. They are sociable creatures, living and working in groups called romps (rafts if they’re in the water).  Otters have been observed to use rocks as tools or even just to keep themselves occupied.  They will even hold on to each other when they sleep so they don’t drift apart.  &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F6dlp39j6jior94bbfak7.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F6dlp39j6jior94bbfak7.jpg" alt="Two Sea Otters Holding Hands"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Be joyful like an otter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fw97j7iclsn77e2iqy16u.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fw97j7iclsn77e2iqy16u.jpg" alt="Three Otters"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As developers we should live by the example of the otter.  If you can’t approach your problems with joy at least attempt to be playful.  Your state of mind is important and affects your team members more than you may realize.&lt;/p&gt;




&lt;h2&gt;
  
  
  Be quizzical like an otter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F45crys1ble2xwx30x7q3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F45crys1ble2xwx30x7q3.png" alt="Otters deep in thought"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Problems are just solutions waiting to be found.  Investigate new patterns and solutions. Stay lean and nimble like an otter, find new ways to do things you already know how to do.  &lt;/p&gt;




&lt;h2&gt;
  
  
  Be social like an otter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F54ypz93lxznoo4tcgnl3.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F54ypz93lxznoo4tcgnl3.jpg" alt="A Raft of Sea Otters"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Make use of your team. They can help you reach personal and professional goals. There is a multitude of resources available to you as a developer. Entire communities on Slack, Discord, Twitter, and other networks and sites are at your fingertips where you will find people more than willing to help you learn or talk about whatever tech you're into.  If you live in a metropolitan area it's possible someone is organizing tech meetups. If not (or even if so) you could start your own.  You could attend a nearby hackathon. It gives you the opportunity to push yourself to do something you normally wouldn't, like work with new people or with ones you  wouldn't usually. It also allows you to see what the other participants and teams are capable of and exposes you to new ideas through interacting with and listening to such a variety of people.&lt;/p&gt;




&lt;h2&gt;
  
  
  Be ingenious like an otter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F46udjpa3v7fazux6ipae.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F46udjpa3v7fazux6ipae.gif" alt="Otter playing with rock"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Make use of the tools at your disposal. FOSS (Free and Open Source Software) is bigger than ever.  That means those tools are available to you as well. Don’t be afraid to have fun either. You can learn a lot through play.  If you want to learn a new language or how  to use a new framework start a project. Pet projects are almost intrinsically valuable.&lt;/p&gt;




&lt;h2&gt;
  
  
  Be an otter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fz56klv2f8zj1np0rv6j2.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fz56klv2f8zj1np0rv6j2.jpg" alt="Sea Otter"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It's difficult to decide how to act in life without a model.  If your goal is to hone your craft as a developer following the model of the otter can take you far both professionally and in your personal quest.  Another model may be a better fit for you personally but at least now you are aware of how to be like an otter.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fmleh5ugiax0ng183zvkw.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fmleh5ugiax0ng183zvkw.jpg" alt="Otter with cupcakes"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>writing</category>
      <category>career</category>
      <category>softwaredevelopment</category>
    </item>
    <item>
      <title>The Case of the Broken Unit Test</title>
      <dc:creator>Jack-DO</dc:creator>
      <pubDate>Fri, 22 Mar 2019 13:01:01 +0000</pubDate>
      <link>https://forem.com/dealeron/the-case-of-the-broken-unit-test-1chh</link>
      <guid>https://forem.com/dealeron/the-case-of-the-broken-unit-test-1chh</guid>
      <description>&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fbgxuqpl5zu4ll02ywap1.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fbgxuqpl5zu4ll02ywap1.jpg"&gt;&lt;/a&gt;Photo by &lt;a href="https://unsplash.com/@ericmuhr" rel="noopener noreferrer"&gt;Eric Muhr&lt;/a&gt; on &lt;a href="https://unsplash.com" rel="noopener noreferrer"&gt;Unsplash&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;One seemingly fine day, I made the mistake of running unit tests locally. There I was minding my own business, having just finished working a ticket on my team’s main project, I decide to be diligent and ensure all tests ran properly. That’s when everything went horribly wrong. “ &lt;code&gt;1 failed ❌&lt;/code&gt;” the Test Explorer exclaimed. Anxiety rising in my throat, panic racing up my back, I started to debug the failing test.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;code&gt;Expected result: -1&lt;/code&gt;&lt;br&gt;&lt;br&gt;
  &lt;code&gt;Actual result: @1&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;@1… AT ONE?!?! There’s no such thing as @1, this is an integer. Fearing the worse I checked out our development branch fresh to ensure I wasn’t the one who had killed the build. Much to my horror I watched the same massacre unfold.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;1 failed ❌&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;It turns out I was not the killer.&lt;/p&gt;

&lt;p&gt;Opening a ticket, I sent an alert to my stalwart team members.&lt;br&gt;&lt;br&gt;
&lt;em&gt;“The development branch is broken, unit tests are failing, no I’m not joking this is serious business!&lt;/em&gt;”&lt;br&gt;&lt;br&gt;
&lt;em&gt;“What are you talking about?”&lt;/em&gt; I hear come over the wall. It’s my team’s Technical Lead. &lt;em&gt;“All tests are passing for me.”&lt;/em&gt;&lt;br&gt;&lt;br&gt;
There, on his screen, right before my own eyes is our precious baby soaring through those units.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;All green ✔️&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F1qyolf5navw37lltuh7o.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F1qyolf5navw37lltuh7o.gif"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I get my partner to do the same.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;All green ✔️&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;OK, now I know its me. Let’s go to the source. The value being faked out by the test is stored in the database in the wild, so I check there.&lt;br&gt;&lt;br&gt;
&lt;code&gt;@1&lt;/code&gt;&lt;br&gt;&lt;br&gt;
… &lt;code&gt;@1&lt;/code&gt;?!? This is an int column!&lt;/p&gt;

&lt;p&gt;I get my partner to query the db: &lt;code&gt;-1&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;The plot thickens. Am I losing my mind? These values aren’t possible and most certainly shouldn’t change based on who views the value in the data store.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsmvhx0qzjtoanzwrqg9v.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsmvhx0qzjtoanzwrqg9v.jpg"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;My dear Watson, what could cause a minus to become an @? Surely there is a logical explanation for this. Wracking my brain the first thing that comes to mind is CultureInfo.CurrentCulture. Eureka! It suddenly comes to me like an electric shock. My culture settings! After discovering how, I open my culture settings. There was the culprit. In the formatting, the negative symbol was set to a an @ sign. This explains everything!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fx8qpfoh25ao733vpi9ga.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fx8qpfoh25ao733vpi9ga.png"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I correct the setting and check the database: -1. My confidence returning, my nerves steadying, I rerun the failing tests.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;All green ✔️&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F2jtof7fpgjpvtkqwd1yq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F2jtof7fpgjpvtkqwd1yq.png"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Jubilation! My Kafkaesque nightmare is over. The existential crisis comes to an end yet again. I do, in fact, know what I’m doing. I haven’t simply stumbled this far through a comedy of errors and found myself dumbfounded in the day to day of my trade. I inform my team members who were involved in helping and anyone else in earshot I think would find it interesting. “You should write a blog post about that” my Department Lead responded on hearing my tale. And that my friend is why you find yourself here.  &lt;/p&gt;

&lt;p&gt;Fin&lt;/p&gt;




</description>
      <category>softwaredevelopment</category>
      <category>debugging</category>
      <category>testing</category>
    </item>
  </channel>
</rss>
