On Wed, 22 Sep 2004 09:08:48 -0400, Brian Kotek <[EMAIL PROTECTED]> wrote:
> Unit testing is always a great idea, but I don't see how that can test
> thread safety.  For example, how would a unit test flag down a situation
> where you missed var scoping a variable since these problems really only
> come out under load?  Is load testing really the only way to be sure?
> 
> Maybe Sean has some pointers?

Correct, you have to do load testing. Download Microsoft's Web
Application Stress Tool (free). There's other free tools out there but
I don't remember the names.

Of course, if you know what you're looking for, you can 'test' by
inspection. Basically you should have *NO* variables in a function
that aren't either:
- fully scope-qualified, e.g., variables.x, arguments.foo
- explicitly declared with 'var' at the top of the function

Watch out for variables created by tags (e.g., <cfquery name="x"...>,
<cfhttp> which creates cfhttp as a variable etc). Also watch out for
<cfloop> - you need to var declare those loop indexes!
-- 
Sean A Corfield -- http://www.corfield.org/blog/

"If you're not annoying somebody, you're not really alive."
-- Margaret Atwood
----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email
to [EMAIL PROTECTED] with the words 'unsubscribe cfcdev' 
in the message of the email.

CFCDev is run by CFCZone (www.cfczone.org) and supported
by Mindtool, Corporation (www.mindtool.com).

An archive of the CFCDev list is available at www.mail-archive.com/[EMAIL PROTECTED]

Reply via email to