Fluent Refactoring @ YouTube

loneStarRuby Conf 2013 – Fluent Refactoring by Sam Livingston-Gray

It’s about refactoring. There have already been many refactoring related videos/documents, but interesting point of this presentation is the “Refactoring is Math” statement.
It iteratively follows through the small set of logical conversions to reshape the code structure.

For example, flattening the multiple layers of if/else statements and re-order them to make it easier to move around. Then, remove the duplication appeared through this process. It’s like mathematical conversions of formula.

In the refactoring process, it’s common to use unit tests to verify the original behavior is being maintained and doesn’t break anything. However, unit tests is not the perfect solution due to the nature of its lack of coverage.

Therefore, minimizing the change of each step would be important, and this kind of mathematical (logical) break-down of modification is interesting approach to reduce the risk of breaking change during the process.

Advertisements

Posted on August 22, 2013, in Conference, Software Design, Web. Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: