Re: Continuous Integration Hell
Posted: Feb 11, 2004 3:13 PM
> > Here's an example. I have unit test that tests the RSS
> > feed grabber that is used in News and Buzz on Artima
> > tests that the socket actually times out if the other
> > is too slow. If after 20 or 30 seconds -- I don't
> > the exact cutoff -- have elapsed and the socket is
> > sucking down data, or more likely waiting for data to
> > arrive, the socket should abort. That unit test sets up
> > socket to another socket that never hangs up, to test
> > timeout. So therefore, that one test takes 20 or 30
> > seconds.
> How about changing it to time out after one second? It
> would be a slight design change, parameterizing the class
> so it can be fast under test but patient during
> production, but it would allow you test the logic without
> taking as long.
Well, I wasn't complaining about the wait. I was just giving an example of a reason to have a longer test. The full test only takes a minute or so to run, inluding the 20 or 30 seconds of this socket timeout test, and that gives me time to stare off into the distance and dream of ocean breezes and swaying palm trees. If the total time were unacceptable, I would likely parameterize the timeout just as you suggest, but then of course I would lose 20 seconds of valuable ocean breezes dreaming time.