News

Speed Up Your Specs

Comments

published Tuesday, February 11, 2014

Just a few references to help you boost your spec suites. Got 50% - 70% speed boost for BookingSync test suite.

  • Inspect with perftools.rb
  • Lower BCrypt Cost
  • Deferer Garbage Collection

References:

http://blog.syncopelabs.co.uk/2012/12/speed-up-rspec-test.html
http://makandracards.com/makandra/950-speed-up-rspec-by-deferring-garbage-collection
http://blog.carbonfive.com/2011/02/02/crank-your-specs/

Rails with SSL in development with POW and Tunnelss

Comments

published Sunday, February 09, 2014


Updated 2014-09-17: Recommend Tunnelss (extra 's') instead of Tunnels to provide valid certificate for .dev domains. (Use carefully, .dev is now a legitimate TLD)

I'm using Pow for running Ruby on Rails Apps in development. One thing not provided by Pow but important to me, is the ability to use SSL in development. For this, I use Tunnelss

Once setup, you'll need to make it run everytime you start your computer, and on OS X Mavericks using rbenv, this can be done by creating the following file:

/Library/LaunchDaemons/org.rubygems.tunnelss.plist

Make sure to adjust the tunnels path to your system

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>Label</key>
  <string>org.rubygems.tunnelss</string>
  <key>ProgramArguments</key>
  <array>
    <string>/Users/seb/.rbenv/shims/tunnelss</string>
  </array>
  <key>RunAtLoad</key>
  <true/>
  <key>UserName</key>
  <string>root</string>
</dict>
</plist>