8 August 2010

Faster cucumber features.

“My tests are running” is the new “My code is compiling”.

Features that take forever to run either make me lose focus or makes it an unpleasant experience dealing with tests.

Recently I was introduced to parallel_tests, a gem that makes use of all the CPU’s on your development machine to run tests in parallel.

Parallel Tests uses the size of feature files as an indication of how long it takes to run, then creates n groups of feature files, where n is the number of processors on your dev machine. Each group is then processed by a CPU.

I managed to reduce the runtime of my features by ~30% using the parallel_tests gem. Your mileage, as always, may vary.

ARTICLE BY
Ivor Paul

- COMMENTS

Gem updates

Since we’ve moved to a new blog, we thought it would be best to give a quick overview of all our current gems and what they do:

Easy Roles

This was our first gem. Easy roles handles role management for users on your Rails application. The gem itself is extremely easy to use, and to setup.

Github: http://github.com/platform45/easy_roles
Rubygems: http://rubygems.org/gems/easy_roles

Easy Dates

Our second gem. It allows you to do predefined date formatting in your model, so you dont have to do it in your views. This allows you to define all formats in one location, and if they need to be changed, you won’t have to dig through your whole application to find all date formatting and change it.

Github: http://github.com/platform45/easy_dates
Rubygems: http://rubygems.org/gems/easy_dates

Speed

This is a really really small gem we wrote to test the speed of a controller, or model’s load time. Simply wrap your code in the speed block, and i’ll output the time it took to execute.

Github: http://github.com/platform45/speed
Rubygems: http://rubygems.org/gems/speed

Stateflow

Our latest gem. Stateflow allows business like transitions in your state machine. Stateflow also supports multiple persistence layers (ActiveRecord, Mongoid, MongoMapper), with an extremely easy API to work with. We wrote this gem in the need of more flexibility within our complex state based models.

Github: http://github.com/ryanza/stateflow
Rubygems: http://rubygems.org/gems/stateflow

We currently use all our gems on production sites, so they are considered stable. Feel free to fork and modify :)

Ryan Oberholzer
7 July 2010

- Comments

6 June 2010

Getting started with MongoDB

We recently did a talk on MongoDB at the monthly capetown.rb meet up.

Take a look at the slides below for a basic introduction to MongoDB, and the main advantages to using mongodb as your next database in your application.

ARTICLE BY
Ryan Oberholzer

- COMMENTS

Hello

We’re Platform45 and this is our new blog.

- Comments

We'd love to hear from you: