Archive for the ‘ruby’ Category


Rails 3: Django with a funny syntax

Posted by Elf Sternberg as python, ruby

From the announcements for Rails 3: The upcoming version 3 of Ruby on Rails will feature a sexy new querying API from ActiveRecord. Here is an example: User.order(‘ DESC’).limit(20).includes(:items) In other words, Rails is now Django. Also: Each application now has it’s own name space, application is started with YourAppName.boot for example, makes interacting with […]


Rails re-affirms my love for Django…

Posted by Elf Sternberg as programming, ruby

I have a contract that I’m working on that requires I work with rails.  That, in itself, isn’t so bad.  But I think what bothers me most about rails can be summed up in one word: partials. For example, let’s say I have the following: render :partial => ‘employee’, :collection => @employees What this means […]

This is part 4 of a series. So far, we’ve written a basic Django application, written some tests for it, checked everything into a central repository, and then integrated those tests with the Hudson continual integration server. But Django’s tests run in a kind of pseudo-server mode, with both the tests and the application running […]

Ah, the bleeding edge.  It’s a war out there! This morning, Facebook released fbwatir. I’ve just spent the past few hours knocking it around, and have come to the conclusion that it’s pretty mega-borked but it can be saved. In fact, I now have it working with Cucumber and Firewatir. There are several major flaws […]


Arrghh… Ruby on Rails.

Posted by Elf Sternberg as ruby

Ruby is just an excuse for people who once loved spaghetti code, who wanted to be “the smartest guy in the room,” and who wanted to be indispensible, to get back at everyone who loved Python and thought that there was finally a decent way to write disciplined code. Everyone talks about how nice Ruby […]

So, remember my comment about unit testing yesterday?  This is what it looks like today. Here’s the features page: Feature: Login In order to use the system As a customer I want to log in Scenario: Access page Given I am at the login page Then the page title should be “SecretProject” Scenario: Log in […]

FireWatir is my preferred testing suite for developing web applications.   Watir is a domain-language that describes things you do with a web browser: navigate to this page, find this input field, type in this text, find this button and click on it.  Combinded with a unit testing framework like Ruby’s Unit::Test, and you can write […]

Until circumstances change, this will just be the most horrible geek tease you can imagine. At the office, we have exactly three approved programming languanges: C for performance, Python for everything else, and a begrudging tolerance for ECMA-262 for the WebUI team and site design. (Although the docs deployment people get away with PHP, which […]

I was working today on my storyengine / storykeeper / narrator codebase when I hit a snag. Storyengine converts text to XML and embeds in into a database. Storykeeper is a little rails program that I use to make sure all my keywords and so forth are set up correctly. And narrator is le grand […]

I know there are people out there who love the way Ruby does some things, but there’s one feature of Ruby that drives me nuts, mostly because it doesn’t do things The One True Way of Python. And that’s call by reference. In Python, everything is a reference. Let’s say you have some methods, and […]

Subscribe to Feed



February 2017
« Jan