Deal of the Day

Home » Main » Manning Forums » 2007 » The Art of Unit Testing

Thread: Listing 1.2 - The code for TestReturnsZeroWhenEmptyString()

Reply to this Thread Reply to this Thread Search Forum Search Forum Back to Thread List Back to Thread List

Permlink Replies: 2 - Pages: 1 - Last Post: Mar 9, 2008 10:42 PM by: wdevine
powerboots

Posts: 8
Registered: 2/2/08
Listing 1.2 - The code for TestReturnsZeroWhenEmptyString()
Posted: Feb 8, 2008 7:05 PM
  Click to reply to this thread Reply

I think the line:
int result = p.ParseAndSum("1");
should be written:
int result = p.ParseAndSum("");

Am I wrong ?!

wdevine

Posts: 3
From: Lake Mary, FL
Registered: 3/9/08
Re: Listing 1.2 - The code for TestReturnsZeroWhenEmptyString()
Posted: Mar 9, 2008 10:38 PM   in response to: powerboots in response to: powerboots
  Click to reply to this thread Reply

I was thinking the same thing.

wdevine

Posts: 3
From: Lake Mary, FL
Registered: 3/9/08
Re: Listing 1.2 - The code for TestReturnsZeroWhenEmptyString()
Posted: Mar 9, 2008 10:42 PM   in response to: wdevine in response to: wdevine
  Click to reply to this thread Reply

Whooops! Should have looked through the forum completely before I commented. This was talked about earlier in the forums:

http://www.manning-sandbox.com/thread.jspa?threadID=20781&tstart=15

Legend
Gold: 300 + pts
Silver: 100 - 299 pts
Bronze: 25 - 99 pts
Manning Author
Manning Staff
Manning Developmental Editor