Submissions by Harley tagged unit-tests

It's not the most fun part of writing software, but html/template is now at 100% coverage. Almost exactly ⅓ of the code resides in html/template, so I still have a fair few more tests to write. Sadly, I think the easiest tests are written. I don't really think the middleware piece is too hard, but really requires the assets piece to be tested. The assets piece does file access & manipulation. I can't help but think that's going to be a bit more challenging to test properly.

I also decided to say screw it and threw the code on Github: https://github.com/losinggeneration/pipeln

Spent a fair amount of time benchmarking the Go code against Sprockets (I was curious.) The Go Javascript serving isn't as fast as the Sprockets implementation currently. One thing that I can think of that could get it closer to that speed would be last modified checks and serving the preprocessed version. Overall though, as far as on my desktop, I wasn't too disappointed with the results. 20ms to serve the Ember.js app (including the debug ember.js & jquery.js files.) compared to 8ms from Rails with Unicorn. Somewhat interesting was the BeagleBone Black took roughly 1400ms to serve the same files from Go. I wasn't able to run the Rails test on BeagleBone Black hardware because...

A good portion of my time was spend trying to figure out why ember-rails on the BeagleBone Black was throwing an "undefined method 'ember'" error when trying to run rails generate ember:bootstrap.

I finished the night off writing unit tests for the template code. I got to about 60% code coverage (of ~150 lines.) Overall, I was pretty happy with how well the code behaved when I started writing tests. A few things that I expected to throw errors or junk output, ended up being handled gracefully. It's likely because I did a fair amount of iterative testing before this point.