Posts tagged Ruby

This is a semi-active blog. Once I write a post, I usually never update them. If you will read through some of these and try to follow them, please do so at your own risk. Technology changes quickly. Established languages are not as cool as they used to be. Some tutorials written several years ago may no longer work and do not reflect present day best practices.

Testing Some Devise Features With RSpec, Steak and Email Spec

rspec ruby steak email devise

Having spent hours writing cucumber tests and finding out that it all doesn't work with Rails 3.1 RC5 is frustrating. It disrupts the flow of things. In my mind all I wanted was to move on to focus on new features. Not being able to write tests for the new features because of incompatibility issues is just hell. That's the only reason why I started using Steak yesterday for acceptance tests.

Continue reading »

Timeline Fu

ruby rails

Realized nearly all of my projects involved logging user actions and having news feeds similar to Facebook. Two years ago, it didn't seem sensible to use a gem for just that because all you need is to create a module and helpers to log actions (on your model of course). A common mistake is adding code for logging actions, sending emails on controllers. Sometimes when you are young, you do stupid things.

Continue reading »

Don't Forget Ruby's Send Method

ruby rails

Goal: we want to display the logo of Twitter, Facebook and Google along with the links if the user is not authenticated (has not successfully authorized the application to access and write data to the third party service) or if the user is not a current user.

Continue reading »

What You Should Know Before You Upgrade Your Rails 3 App To Rails 3.1 Beta

rails ruby

There were many issues. But they aren't much compared to the benefits you'd get from using the latest version. Rails 3.1 takes away a lot of pain. Instead of using asset packager, having sprockets makes it so much easier to deploy an optimized application. Not all frameworks have this. In fact it hasn't been a practice of certain developers to make sure that a single file is loaded for javascript in production and a single is loaded for stylesheet in production. Reversible migrations is another cool thing. Also read that there is no need to add ":multipart=>true" on a form if you use the file field.

Continue reading »

Hello! I am Kat. I've been a developer for several years. When I'm not sitting down, reading and working for long hours, I am traveling to some place of interest.
If you want to reach out, you can send me an email or add me up on Google Plus.