Brian Mcardle wrote:
> But as you point out, this is impossible. We'll say I never thought of 
> testing for non-English characters in certain strings. All my fixtures 
> are English, all my tests pass. One of my users creates a record with a 
> 'รก' character... maybe nothing breaks. Maybe on a later upgrade, I add a 
> new page, and that breaks.

I was actually speaking in generalities. However, I still don't think 
scenarios like you mentioned are worth the overhead of testing against 
production data, which will be high. And, even then, you're still going 
to have scenarios that testing against live data won't catch. In either 
case you're going to discover the problem after it has happened.

You're example illustrates this rather nicely. It would be easy to 
overlook accented character handling if you not expecting them. Whether 
you test against live data or not, you would not have prevented the 
problem from happening. The error would have already had to have 
happened. If this caused an error, and the exception notification was in 
place to report the error, then adding a test (or spec) to prevent this 
issue once know has the same effect as testing against live data without 
the huge overhead.

That being said if the facilities were not in place to begin with, then 
doing a "one-time" test against the data you have received up to this 
point might be useful. Just not something you want to rely upon 
long-term.
-- 
Posted via http://www.ruby-forum.com/.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to