<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">

 <title>mt7.de - feed</title>
 <link href="http://mt7.de/atom.xml" rel="self"/>
 <link href="http://mt7.de/"/>
 <updated>2016-06-13T20:07:31+12:00</updated>
 <id>http://mt7.de</id>
 <author>
   <name>Thorsten Böttger</name>
   <email>boettger@mt7.de</email>
 </author>

 
 <entry>
   <title>Making of</title>
   <link href="http://mt7.de/personal/2016/06/13/making-of.html"/>
   <updated>2016-06-13T00:00:00+12:00</updated>
   <id>http://mt7.de/personal/2016/06/13/making-of.html</id>
   <content type="html">&lt;p&gt;
  Let&#39;s get started, using a pencil.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Making of, part 1&#39; class=&#39;full&#39; src=&#39;/images/content/making_of_1.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Trace it using a fineliner.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Making of, part 2&#39; class=&#39;full&#39; src=&#39;/images/content/making_of_2.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Getting rid of those pencil strokes.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Making of, part 3&#39; class=&#39;full&#39; src=&#39;/images/content/making_of_3.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Done.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Making of, part 4&#39; class=&#39;full&#39; src=&#39;/images/content/making_of_4.jpg&#39;&gt;
&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Family car</title>
   <link href="http://mt7.de/personal/2016/06/12/family-car.html"/>
   <updated>2016-06-12T00:00:00+12:00</updated>
   <id>http://mt7.de/personal/2016/06/12/family-car.html</id>
   <content type="html">&lt;p&gt;
  &lt;img alt=&#39;People mover for 8&#39; class=&#39;full&#39; src=&#39;/images/content/family_car.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Yep, we own a family car, a people mover for 8.
&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Our house in 82 Sunshine Ave, Karori</title>
   <link href="http://mt7.de/personal/2016/06/11/house-82-sunshine-ave.html"/>
   <updated>2016-06-11T00:00:00+12:00</updated>
   <id>http://mt7.de/personal/2016/06/11/house-82-sunshine-ave.html</id>
   <content type="html">&lt;p&gt;
  &lt;img alt=&#39;Our house in 82 Sunshine Ave&#39; class=&#39;full&#39; src=&#39;/images/content/house_82_sunshine_ave.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Backside of our house in 82 Sunshine Ave, Karori, Wellington, New Zealand.
&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>2014 – a year in review</title>
   <link href="http://mt7.de/personal/2015/04/20/2014-a-year-in-review.html"/>
   <updated>2015-04-20T00:00:00+12:00</updated>
   <id>http://mt7.de/personal/2015/04/20/2014-a-year-in-review.html</id>
   <content type="html">&lt;p&gt;I think it’s good practice to list up all the things you achieved in a year. It’s not
really about telling others and brag about it. No, it’s more about telling yourself
and calm down (&lt;a href=&quot;http://en.wikipedia.org/wiki/Impostor_syndrome&quot;&gt;impostor syndrome&lt;/a&gt; anyone?).&lt;/p&gt;

&lt;p&gt;So let’s talk about 2014. We (my wife, our five boys and me) were living in
&lt;a href=&quot;http://en.wikipedia.org/wiki/Hamburg&quot;&gt;Hamburg, Germany&lt;/a&gt; they whole year and I was
working as a freelancing software developer most of the time. Besides that…&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;While working for &lt;a href=&quot;https://www.xing.com&quot;&gt;XING AG&lt;/a&gt; I helped building the new
&lt;a href=&quot;https://www.xing.com/communities&quot;&gt;Communities&lt;/a&gt; product, a replacement for
the old &lt;em&gt;Groups&lt;/em&gt;. It finally took us one and a half years to get there. What
sounds like a simple forum or blackboard application is actually much more,
especially implementing access control and integration into the rest of
the XING universe.&lt;/li&gt;
  &lt;li&gt;I took a look into programming with &lt;a href=&quot;http://elixir-lang.org&quot;&gt;Elixir&lt;/a&gt; and
&lt;a href=&quot;https://golang.org&quot;&gt;Go&lt;/a&gt;, and both are very promising alternatives to
my current favorite &lt;a href=&quot;https://www.ruby-lang.org/&quot;&gt;Ruby&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;I tried using the &lt;a href=&quot;https://atom.io&quot;&gt;Atom editor&lt;/a&gt;. It’s a very good text
editor, with lots of nifty feature for programmers and already with
a big community. Nonetheless, I finally stayed with
&lt;a href=&quot;http://www.sublimetext.com&quot;&gt;Sublime Text&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;We decided to return to New Zealand. It’s where currently our heart is.
We didn’t finish this chapter of our life last time (in 2012/13), so
we had to go back (I’m currently writing this post in Wellington, New
Zealand)&lt;/li&gt;
  &lt;li&gt;I played around with &lt;a href=&quot;https://www.docker.com&quot;&gt;Docker&lt;/a&gt;. It’s more than
just a new kid on the block, it’s the near future. It’s already mature,
ready to use even in production and comes with a very big community (I
somehow got the feeling this is important).&lt;/li&gt;
  &lt;li&gt;I went to two conferences this year. The first one is
&lt;a href=&quot;http://2014.scottishrubyconference.com&quot;&gt;Scottish Ruby Conf&lt;/a&gt;
in Edinburgh and Crieff, Scotland, a typical Ruby conference
with lots of enthusiastic and caring people and topics about, well,
Ruby. The second one is
&lt;a href=&quot;http://beyondtellerrand.com/2014/&quot;&gt;Beyond Tellerrand&lt;/a&gt;, a conference
about working with and living in the Internet, not only about development
or design. It’s an amazing event, highly recommended!&lt;/li&gt;
  &lt;li&gt;I released version 4 of &lt;a href=&quot;https://github.com/aasm/aasm/&quot;&gt;AASM&lt;/a&gt;, one of the
open source projects I’m maintaining. It actually took more than a year
to finish this up, so I’m glad it’s out of the door.&lt;/li&gt;
  &lt;li&gt;I gave a talk about &lt;a href=&quot;https://github.com/aasm/aasm/&quot;&gt;AASM&lt;/a&gt; at
the &lt;a href=&quot;http://hamburg.onruby.de&quot;&gt;Hamburg Ruby User Group&lt;/a&gt; meetup.
General topic was
&lt;a href=&quot;http://hamburg.onruby.de/events/ruby-usergroup-hamburg-dezember-2014&quot;&gt;Open Source made in Hamburg&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;I had to learn that communication is hard. It all started with me creating
an &lt;a href=&quot;https://github.com/radar/paranoia/issues/173&quot;&gt;issue for paranoia&lt;/a&gt;, asking
for a new release, and ended with a dispute on twitter.
I finally met this guy on the &lt;a href=&quot;http://www.rubyconf.org.au/2015&quot;&gt;RubyConf Australia&lt;/a&gt;
in Melbourne, Australia, and talked to him about that issue. Still, communication
is hard.&lt;/li&gt;
  &lt;li&gt;I participated in the &lt;a href=&quot;http://railsrumble.com&quot;&gt;Rails Rumble&lt;/a&gt;, together with
&lt;a href=&quot;http://jan.krutisch.de&quot;&gt;Jan Krutisch&lt;/a&gt;,
&lt;a href=&quot;http://florian.munz.org&quot;&gt;Florian Munz&lt;/a&gt; and
&lt;a href=&quot;http://twitter.com/deetee&quot;&gt;Denise Tham&lt;/a&gt;. We built
&lt;a href=&quot;http://www.awesomerecipes.io&quot;&gt;Awesome Recipes&lt;/a&gt;, which you can use to
visually create kitchen recipes and share them with others.
We finally made it to the 9th place, and we are overall very happy
with the result.&lt;/li&gt;
  &lt;li&gt;We travelled to &lt;a href=&quot;http://en.wikipedia.org/wiki/Sweden&quot;&gt;Sweden&lt;/a&gt; for the
fourth time, and I can only say that we enjoyed it pretty much, again,
and we will definitely come back for a fifth time (once we return
to Europe).&lt;/li&gt;
  &lt;li&gt;I migrated our previous Rails Rumble project, the
&lt;a href=&quot;http://awesome-fontstacks.com&quot;&gt;Awesome Fontstacks&lt;/a&gt;, from
Rails version 3 to 4.&lt;/li&gt;
  &lt;li&gt;I implemented JSON views, which are simple Ruby files evaluated
as Rails views and delivering JSON strings.&lt;/li&gt;
  &lt;li&gt;We visited &lt;a href=&quot;http://en.wikipedia.org/wiki/Stralsund&quot;&gt;Stralsund&lt;/a&gt;
and &lt;a href=&quot;http://en.wikipedia.org/wiki/Rügen&quot;&gt;Rügen&lt;/a&gt;. If you find the
time, go there and have a look yourself. Both are really beautiful.&lt;/li&gt;
  &lt;li&gt;I read a couple of fictional books, one of which of which I can highly
recommend (sorry, German only):
&lt;a href=&quot;http://www.amazon.de/BLACKOUT-Morgen-ist-spät-Roman/dp/3442380294/ref=sr_1_1?ie=UTF8&amp;amp;qid=1429520341&amp;amp;sr=8-1&amp;amp;keywords=blackout&quot;&gt;Blackout&lt;/a&gt; written by
Marc Elsberg.&lt;/li&gt;
  &lt;li&gt;I finally read &lt;a href=&quot;http://www.amazon.de/Candid-oder-Die-Beste-Welten/dp/3150065496/ref=sr_1_sc_1?ie=UTF8&amp;amp;qid=1429520479&amp;amp;sr=8-1-spell&amp;amp;keywords=voltairr&quot;&gt;Candid&lt;/a&gt; written by Voltaire (again, sorry, German only).&lt;/li&gt;
  &lt;li&gt;Together with my eldest son I visited the Thalia theatre in Hamburg,
Germany, where they played &lt;a href=&quot;http://en.wikipedia.org/wiki/Moby-Dick&quot;&gt;Moby Dick&lt;/a&gt;
without any (!) stage setting. Very, very good acting!&lt;/li&gt;
  &lt;li&gt;I set up my wife as the beneficiary for all of my insurances.&lt;/li&gt;
  &lt;li&gt;I started to use &lt;a href=&quot;http://pants.social&quot;&gt;#pants&lt;/a&gt;, a light-weight blogging engine
coming with a fully decentralized social network built-in (I couldn’t have said
that any better than &lt;a href=&quot;http://hmans.io&quot;&gt;Hendrik&lt;/a&gt; himself.&lt;/li&gt;
  &lt;li&gt;I switched from &lt;a href=&quot;http://www.blacktree.com&quot;&gt;Quicksilver&lt;/a&gt; to
&lt;a href=&quot;http://www.alfredapp.com&quot;&gt;Alfred&lt;/a&gt;, and I haven’t regretted it until today.&lt;/li&gt;
  &lt;li&gt;I was part of the Hacktable team organising a couple of
&lt;a href=&quot;http://www.makerhub.de/superkids/&quot;&gt;Superkids events&lt;/a&gt;, allowing kids
to take a look into programming and working with computers.&lt;/li&gt;
  &lt;li&gt;I merged two &lt;a href=&quot;https://www.instapaper.com/&quot;&gt;Instapaper&lt;/a&gt; accounts into one. Yes,
I manually copied over links from one account to the other. If there’s a better
way to do this, I don’t want to know.&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://twitter.com/_benny&quot;&gt;Benny&lt;/a&gt; and I abandoned
&lt;a href=&quot;https://twitter.com/blanksand&quot;&gt;blanksand&lt;/a&gt;, our shared office space
in the centre of Hamburg, Germany. It was finally too much effort to keep things
up and we didn’t use it enough. Sad, but true.&lt;/li&gt;
  &lt;li&gt;We bought a SUP for
&lt;a href=&quot;http://en.wikipedia.org/wiki/Standup_paddleboarding&quot;&gt;Standup paddleboarding&lt;/a&gt;.
Not cheap, but hell lot of fun. You should try it!&lt;/li&gt;
  &lt;li&gt;I reviewed a book about
&lt;a href=&quot;https://www.packtpub.com/big-data-and-business-intelligence/redis-applied-design-patterns&quot;&gt;Redis Applied Design Patterns&lt;/a&gt;.
Check it out if you are interested in working with &lt;a href=&quot;http://redis.io&quot;&gt;Redis&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

</content>
 </entry>
 
 <entry>
   <title>We take care</title>
   <link href="http://mt7.de/business/2014/02/05/we-take-care.html"/>
   <updated>2014-02-05T00:00:00+13:00</updated>
   <id>http://mt7.de/business/2014/02/05/we-take-care.html</id>
   <content type="html">&lt;h2 id=&quot;we-write-idiomatic-code&quot;&gt;We write idiomatic code&lt;/h2&gt;
&lt;p&gt;When we write Ruby code, we do it the Ruby-way. Same goes with Javascript
or Perl or Go. We read code a lot and know how to use language-specific benefits
and avoid the drawbacks. Our code is not different from any other code.&lt;/p&gt;

&lt;h2 id=&quot;we-follow-rails-conventions&quot;&gt;We follow Rails conventions&lt;/h2&gt;
&lt;p&gt;Ruby on Rails comes with its own set of assumptions and conventions (which
is why it is called &lt;em&gt;opinionated&lt;/em&gt;). We are not only aware of these, but we
follow them in our everyday work. Recommended reading
&lt;a href=&quot;http://www.amazon.de/The-Rails-Addison-Wesley-Professional-Ruby/dp/0321601661/ref=sr_1_1?ie=UTF8&amp;amp;qid=1391266175&amp;amp;sr=8-1&amp;amp;keywords=the+rails+way&quot;&gt;The Rails 3 Way, Obie Fernandez&lt;/a&gt;.&lt;/p&gt;

&lt;h2 id=&quot;we-follow-common-styleguides&quot;&gt;We follow common styleguides&lt;/h2&gt;
&lt;p&gt;There are a couple of good styleguides around on GitHub and others. We
know them, we use them and we highly recommend them. Even to the point to
force ourselves by setting up these guides in our editors. For example
&lt;a href=&quot;https://github.com/styleguide/ruby&quot;&gt;Styleguide for Ruby&lt;/a&gt;.&lt;/p&gt;

&lt;h2 id=&quot;we-use-best-practices&quot;&gt;We use best practices&lt;/h2&gt;
&lt;p&gt;We visit conferences and read books to know how the good guys write code.
We listen to people telling us about not the better ways, but the best
ways to achieve our goals. Every day.&lt;/p&gt;

&lt;h2 id=&quot;we-read-all-the-commits&quot;&gt;We read all the commits&lt;/h2&gt;
&lt;p&gt;It’s our codebase. We love it and we don’t want anyone destroying it.
This is why we read any commit coming in. I mean literally, &lt;strong&gt;every commit&lt;/strong&gt;.&lt;/p&gt;

&lt;h2 id=&quot;we-do-pair-programming&quot;&gt;We do pair programming&lt;/h2&gt;
&lt;p&gt;If the issue to tackle is complicated, or we just want to talk to someone
while writing code, we simple ask anyone to join us in doing the work. Call
it 4-eye-principle, Wackeldackel or Rubberduck, it’s on our toolbelt, ready
to be used when needed.&lt;/p&gt;

&lt;h2 id=&quot;we-have-a-refactoring-board-from-which-we-pick-regularly&quot;&gt;We have a refactoring board, from which we pick regularly&lt;/h2&gt;
&lt;p&gt;Technical debt is everywhere. Our means to tackle this pile of guilt is
our refactoring board, which grows and shrinks, visible for each and everyone.
No process needed. There is always time to change existing and running
code. No broken windows allowed.&lt;/p&gt;

&lt;h2 id=&quot;we-use-pull-requests-to-review-code&quot;&gt;We use pull-requests to review code&lt;/h2&gt;
&lt;p&gt;We have a number of ways to push our code to the repository. Sending pull
requests is one of them. We ask others to take a look (or even ask ourselves
one day later), before we let it go into the wild. Simple and effective, if
needed.&lt;/p&gt;

&lt;h2 id=&quot;we-talk-about-our-code&quot;&gt;We talk about our code&lt;/h2&gt;
&lt;p&gt;There’s a plethora of chances to talk about our codebase. Stand-ups,
coffee-times, ad-hoc discussions, lunchtime, and so on. Non-coders
disrespectfully shake their heads on us talking so much about our work.
We always talk about major code changes long before we implement them.&lt;/p&gt;

&lt;h2 id=&quot;we-know-what-everybody-is-working-on&quot;&gt;We know what everybody is working on&lt;/h2&gt;
&lt;p&gt;In order to avoid conflicts we tell others what we are working on. No
surprises, and no major merge conflicts. And even if we are working
in the same code area, we are able to handle any conflict showing up.&lt;/p&gt;

&lt;h2 id=&quot;we-know-our-co-workers&quot;&gt;We know our co-workers&lt;/h2&gt;
&lt;p&gt;By working together every day, we know each others leanings, our strengths
and weaknesses. So we know when we have to support each other on tackling
complex problems and writing code. Even when someone tries something new
and experiments around, we trust what they are doing, because we know
they are doing right.&lt;/p&gt;

&lt;h2 id=&quot;we-seek-code-smells&quot;&gt;We seek code smells&lt;/h2&gt;
&lt;p&gt;Whenever we write code, we take a look around, identifying and marking
code smells. We utilize TODO, FIXME and QUESTION a lot, and find the time
to decover these spots and remove them.&lt;/p&gt;

&lt;h2 id=&quot;we-modularize-our-code&quot;&gt;We modularize our code&lt;/h2&gt;
&lt;p&gt;Even with all conventions, the codebase grows to a point where it is no
longer maintainable. We sport modules, mixins, concerns, gems, plugins,
packages. We know when to use inheritance and STI or composition. We do
this to remain focused on our given business case.&lt;/p&gt;

&lt;h2 id=&quot;we-test&quot;&gt;We test&lt;/h2&gt;
&lt;p&gt;A lot. All kinds of tests. Sometimes first and sometimes after we write
the actual code. No bug without adding a test. No refactoring without a test.
To write a test it to write code. We utilize test coverage, but 100% is
not our goal. That’d be insane. There’s a kind of test for each usecase.
We use the one most appropriate.&lt;/p&gt;

&lt;h2 id=&quot;we-struggle-for-fast-tests&quot;&gt;We struggle for fast tests&lt;/h2&gt;
&lt;p&gt;While writing tests is important, having a fast test suite is equally important.
Slow tests won’t be run, it’s simple as that. That’s why we observe the
trend on Jenkins (or Travis CI).&lt;/p&gt;

&lt;h2 id=&quot;we-check-the-performance&quot;&gt;We check the performance&lt;/h2&gt;
&lt;p&gt;Every code change might have an impact. This is why we do &lt;em&gt;log-jammin’&lt;/em&gt;.
We do it regularly and a lot. Logjam is a great tool for that.&lt;/p&gt;

&lt;h2 id=&quot;we-update&quot;&gt;We update&lt;/h2&gt;
&lt;p&gt;We not only keep our tools up-to-date, we keep the tiny bits of libraries
and packages up-to-date as well. We not only update gems mentioned in
the &lt;em&gt;check-gem-versions&lt;/em&gt; build, we check for rarely used or development-only
gems as well.&lt;/p&gt;

&lt;h2 id=&quot;we-give-back&quot;&gt;We give back&lt;/h2&gt;
&lt;p&gt;Monkey-patching is easy. And dangerous. This is why we have a natural tendency
to return our code changes back to the original developers, in order to
improve their code and let ours grow smoothly and independently. We pullup
a lot.&lt;/p&gt;

&lt;h2 id=&quot;we-organize-our-codebase&quot;&gt;We organize our codebase&lt;/h2&gt;
&lt;p&gt;Rails provides good means to organize the code. But that’s not sufficient.
There are authorizers, utilities, external APIs, decorators and so on.
And there’s a neat little place for all of them.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>dConstruct 2013</title>
   <link href="http://mt7.de/business/2013/09/05/dconstruct-2013.html"/>
   <updated>2013-09-05T00:00:00+12:00</updated>
   <id>http://mt7.de/business/2013/09/05/dconstruct-2013.html</id>
   <content type="html">&lt;p&gt;Back in Brighton, England for the &lt;a href=&quot;http://2013.dconstruct.org&quot;&gt;dConstruct&lt;/a&gt; conference, after 2008 and 2010. If it wouldn’t be for the conference, visiting Brighton is worth all the time. Easy to get there (choose &lt;a href=&quot;http://www.gatwickairport.com&quot;&gt;Gatwick Airport&lt;/a&gt; as your destination, and take the &lt;a href=&quot;http://www.firstcapitalconnect.co.uk&quot;&gt;First Capital Connect&lt;/a&gt; train for 30 minutes), grab a bed in any hotel close to the beach and make your way around. It’s marvelous!&lt;/p&gt;

&lt;p&gt;But the dConstruct conference is worth attending, too, and your time and money couldn’t be spent any more unrepentantly. I got repeatedly asked what the conference is all about, and to be honest, it’s not easy to answer. From what &lt;a href=&quot;http://clearleft.com&quot;&gt;Clearleft&lt;/a&gt; and others state on its website itself, it is a collection (a &lt;a href=&quot;http://en.wikipedia.org/wiki/Smörgåsbord&quot;&gt;smörgåsbord&lt;/a&gt;) &lt;em&gt;“of clever clogs gathered together to twist our perceptions of technology and culture”&lt;/em&gt;. Yeah, that fits. It’s about technology for sure (lots of web developers and designers around), and it’s about culture as well, regarding all the Internet, but even more than that. It’s about how we see the world, what drives our motivation and inspiration. And anytime I get back home, I’m more focused and inspired than before. It’s about that, finding your place in the world around you.&lt;/p&gt;

&lt;p&gt;It’s good to be back.&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>All along the watchtower</title>
   <link href="http://mt7.de/personal/2013/08/25/all-along-the-watchtower.html"/>
   <updated>2013-08-25T00:00:00+12:00</updated>
   <id>http://mt7.de/personal/2013/08/25/all-along-the-watchtower.html</id>
   <content type="html">&lt;blockquote&gt;
  &lt;span class=&#39;apostroph&#39;&gt;&amp;ldquo;&lt;/span&gt;
  &lt;p&gt;
    All I&#39;ve got is a red guitar,
    &lt;br&gt;
    three chords, and the truth.
    &lt;br&gt;
    All I&#39;ve got is a red guitar,
    &lt;br&gt;
    the rest is up to you.
  &lt;/p&gt;
  &lt;cite&gt;
    taken from
    &amp;ldquo;All along the watchtower&amp;rdquo;
    by Bob Dylan
  &lt;/cite&gt;
&lt;/blockquote&gt;
</content>
 </entry>
 
 <entry>
   <title>Valid fixtures</title>
   <link href="http://mt7.de/business/2012/11/01/valid-fixtures.html"/>
   <updated>2012-11-01T00:00:00+13:00</updated>
   <id>http://mt7.de/business/2012/11/01/valid-fixtures.html</id>
   <content type="html">&lt;h2&gt;tl;dr&lt;/h2&gt;
&lt;p&gt;
  Validate your fixtures.
&lt;/p&gt;
&lt;h2&gt;Details&lt;/h2&gt;
&lt;p&gt;
  As mentioned in our
  &lt;a href=&#39;http://soundcloud.com/ploppcasts/ploppcasts-005-testing&#39;&gt;Ploppcasts session about Testing&lt;/a&gt;
  (German only, sorry) I&#39;m using both fixtures and
  factories when testing my Rails applications. One of the drawbacks from
  using fixtures is that these don&#39;t have to be valid in terms of
  &lt;a href=&#39;http://api.rubyonrails.org/classes/ActiveModel/Validations.html&#39;&gt;ActiveModel validations.&lt;/a&gt;
  In order to make sure my fixtures are in fact valid I introduced a fixtures test, which is simply
  a unit test to automatically verify the fixtures&#39; validity:
&lt;/p&gt;
&lt;p&gt;
  &lt;script src=&quot;https://gist.github.com/3991095.js?file=fixtures_test.rb&quot;&gt;&lt;/script&gt;
&lt;/p&gt;
&lt;p&gt;
  So, taken these fixtures:
&lt;/p&gt;
&lt;p&gt;
  &lt;script src=&quot;https://gist.github.com/3991095.js?file=users.yml&quot;&gt;&lt;/script&gt;
&lt;/p&gt;
&lt;p&gt;
  the test will indicate one failure, because the fixture
  &lt;strong&gt;user_without_email&lt;/strong&gt;
  is invalid. The fixture
  &lt;strong&gt;invalid_user&lt;/strong&gt;
  won&#39;t be marked as failure, because its name is starting with
  &lt;em&gt;invalid_&lt;/em&gt;
  telling the test that it should expect an invalid fixture, and
  return a failure otherwise. By this, we can keep having even invalid fixtures
  without failing tests.
&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Painted a year ago</title>
   <link href="http://mt7.de/personal/2012/10/08/painted-a-year-ago.html"/>
   <updated>2012-10-08T00:00:00+13:00</updated>
   <id>http://mt7.de/personal/2012/10/08/painted-a-year-ago.html</id>
   <content type="html">&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of bird painted with chalk&#39; class=&#39;full&#39; src=&#39;/images/content/bird_on_the_street.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Roughly a year ago a very good friend of mine,
  &lt;a href=&#39;http://www.nonuts.de&#39;&gt;Benjamin Rabe,&lt;/a&gt;
  was organising an event for
  &lt;a href=&#39;http://www.fingerpainted.it&#39;&gt;iPhone fingerpainters&lt;/a&gt;
  from all over the world. He invited them to come over to our shared
  office space and have a couple of drinks. I can&#39;t remember who came up
  with the idea, but we finally bought a bunch of paint tubes and asked
  the painters to try and somehow return to real painting, with real paint
  and a real canvas. And since all of them should do it together, the canvas
  simply had to be one of our office walls.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting in progress&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_1.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Over the next couple of hours, these guys really went into something, and
  so the painting on our wall grew and grew.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting in progress&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_2.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  And it grew even further.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting in progress&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_3.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  We really had good fun watching the work in progress. Everybody, even guests without prior
  painting experience, was giving it a try. Everybody was invited to fill the wall up and
  paint what they were feeling like.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting in progress&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_4.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  Everybody was in a flow. Even when waiting outside, it was a nice and warm night, the
  people couldn&#39;t stop painting, this time using crayons, and they went on painting little
  pictures on the street.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting on the streets using chalk&#39; class=&#39;full&#39; src=&#39;/images/content/chalk_group.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  After having painted for almost 5 hours, everybody was happy with the result and
  proud of being part of this happening. The final picture is about 5 meters wide and
  almost 3 meters high, and it does not fit in full size on the following image.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of finished fingerpainting&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_finished_wall.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  But feel invited to come over and take a look yourself! The painting is still there
  and will be around until we leave the office to the next residents. When coming
  back to the office the next morning, we were glad it haven&#39;t rained yet and the chalk
  paintings outside were still visible.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of finished chalk fingerpainting&#39; class=&#39;full&#39; src=&#39;/images/content/chalk_next_day.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  When taking a closer look at the big painting inside, I noticed a number of
  nifty details.
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting details&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_detail_1.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting details&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_detail_2.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  &lt;img alt=&#39;Instagram Photo of fingerpainting details&#39; class=&#39;full&#39; src=&#39;/images/content/fingerpainting_detail_3.jpg&#39;&gt;
&lt;/p&gt;
&lt;p&gt;
  It was just a wonderful evening. Thanks to everyone who was taking part in this, and even
  more thanks to the guy who created this living and one-of-a-kind experience, Benjamin Rabe!
&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Why do I add to_s methods to a Ruby class?</title>
   <link href="http://mt7.de/business/2012/10/03/why-do-i-add-to_s-methods.html"/>
   <updated>2012-10-03T00:00:00+13:00</updated>
   <id>http://mt7.de/business/2012/10/03/why-do-i-add-to_s-methods.html</id>
   <content type="html">&lt;h2&gt;tl;dr&lt;/h2&gt;
&lt;p&gt;
  Adding a to_s method to a Ruby class helps with debugging.
&lt;/p&gt;
&lt;h2&gt;Details&lt;/h2&gt;
&lt;p&gt;
  I more and more tend to add to a Ruby class I want to test is a to_s method returning
  some sort of information about the underlying object.
&lt;/p&gt;
&lt;p&gt;
  &lt;script src=&quot;https://gist.github.com/3825749.js?file=simple_class_with_to_s.rb&quot;&gt;&lt;/script&gt;
&lt;/p&gt;
&lt;p&gt;
  So whenever I have to dig a little deeper and have to debug code that uses an instance of
  that class or I simply want to write some details to the logfile, I can use the returned
  string and thereby make sure all relevant information is printed.
&lt;/p&gt;
&lt;p&gt;
  &lt;script src=&quot;https://gist.github.com/3825749.js?file=usage.rb&quot;&gt;&lt;/script&gt;
&lt;/p&gt;
&lt;p&gt;
  Returning only a hard-coded string or name doesn&#39;t make any sense at all though. So, let&#39;s
  assume we have some sort of business object, for example a job doing some kind of work in
  the background. It has a certain state which we want to know about:
&lt;/p&gt;
&lt;p&gt;
  &lt;script src=&quot;https://gist.github.com/3825749.js?file=job.rb&quot;&gt;&lt;/script&gt;
&lt;/p&gt;
&lt;p&gt;
  If you put this into an application which keeps the waiting user up-to-date with the current
  state of processing (as simulated below with a Ruby irb console), the user knows exactly
  what&#39;s going on.
&lt;/p&gt;
&lt;p&gt;
  &lt;script src=&quot;https://gist.github.com/3825749.js?file=jobs.rb&quot;&gt;&lt;/script&gt;
&lt;/p&gt;
&lt;p&gt;
  There are more methods a Ruby class should have. Make sure to take a look at Robert Klemme&#39;s
  &lt;a href=&#39;http://blog.rubybestpractices.com/posts/rklemme/018-Complete_Class.html&#39;&gt;&quot;The Complete Class&quot; article.&lt;/a&gt;
  I don&#39;t think a class should contain all of the methods described there, but it&#39;s a good starting
  point.
&lt;/p&gt;
</content>
 </entry>
 

</feed>
