If you are using BE DE DE or TE DE DE, then you will get situations in your specs or tests where you want to be able to just create a valid model of another type to test against. This is where factories and builders come in handy.

Read the rest of this entry

Are you a real programmer?

December 5th, 2007

I might be biased, I might be talking from a lack of experience, but if you are reading this and you are not involved in an open source project, then you are not a real programmer…

Read the rest of this entry

S.I.M.P.L.E

December 5th, 2007

THE LESSER-KNOWN PROGRAMMING LANGUAGES #10: SIMPLE

SIMPLE is an acronym for Sheer Idiot’s Monopurpose Programming Language
Environment. This language, developed at the Hanover College for
Technological Misfits, was designed to make it impossible to write code
with errors in it. The statements are, therefore, confined to BEGIN,
END and STOP. No matter how you arrange the statements, you can’t make
a syntax error. Programs written in SIMPLE do nothing useful. Thus
they achieve the results of programs written in other languages without
the tedious, frustrating process of testing and debugging.

(Care of OpenBSD forturne)

Playing with PCs is no fun

December 1st, 2007

I work on a Mac. Lots. Recently I have had to do some rails work on a PC… and going back to WindowsXP is NO fun at all…

Read the rest of this entry

ActiveRecord works well when we are saving strings and integers, but what if you want to save a real, live, honest-to-God Ruby OBJECT like a TMail::Mail instance?? Well.. serialize to the rescue!

Read the rest of this entry

Why use lambda in RSpec?

November 15th, 2007

RSpec allows you to write nice readable tests… and some little tricks make it even nicer! And I don’t know about you, but the word lambda is (1) ugly, (2) means basically bugger all and (3) is hard to pronounce late at night… so lets replace it!

Read the rest of this entry