|
Programming Ruby - The Pragmatic Programmer's Guide
|
Last Update 2006/7/28 6:47
|
Category
Programming
Ruby
|
Description
This book is a tutorial and reference for the Ruby programming language. Use Ruby, and you'll write better code, be more productive, and enjoy programming more. These are bold claims, but we think that after reading this book you'll agree with them. And we have the experience to back up this belief.
|
Hits: 24
|
Real world Rails, Part 4: Testing strategies in Ruby on Rails
|
Last Update 2007/8/21 5:55
|
Category
Software Testing and Quality Assurance
Software Testing
:
Programming
Tools
:
Programming
Ruby
|
Description
One of the most distinctive aspects of the Rails platform is the Ruby language itself. As a dynamically typed language, Ruby has great flexibility, convenience, and power, but at a cost. Dynamically typed languages do not have a compiler that can catch certain kinds of errors, including relatively common type errors and some misspellings. Very early on, users of dynamically typed object-oriented languages learned that they had to test. Without testing, Ruby applications would have a much higher incidence of error per line of code than they do. With testing, you can have the benefits of dynamically typed languages with much less of the downside. In this article, I won't bore you with basic decisions, like whether you should test at all, or how you can convince your managers that the testing effort is worthwhile. I'll assume you already test. Instead, I'll break down some of the more subtle testing decisions that every Ruby project lead must eventually make. I'll talk about how you can measure your testing coverage, and how much testing you should do. I'll walk you through the basic out-of-the-box testing techniques, and how those compare with the newer mocking frameworks. Rather than providing an exhaustive tutorial, I'll give you a few examples of the techniques we used to build ChangingThePresent.org (see Resources) so you'll have a basic flavor of the techniques in play. Then I'll break through the strengths and weaknesses of the various techniques as we see them.
|
Hits: 28
|
|
|
|