Re: Re: Refactoring QueryHits::prepareReadPayload

Peter Dimov wrote:

…..

P.S. I wouldn’t like to change too much Gnutella::Packets just for the sake of experimentation.

….

Are you referring to the changes  ( or kind of changes ) like the ones I proposed…

If so, I understand ;-) It is usually a tight rope walk…

It really all depends on the tests… Exhaustive unit test suite which will tell me right away if I broke something…

What about CppUnit? CppUnit is a beauty… I started to pull Caltiko code into a test harness, but thought I would ask here first…

Separating out classes, and putting Unit Tests in is not simple but gives you a greater understanding… ( I could run some complex method into gdb and experiment with various  input …)

I have a copy of Mike Feather’s book and used some of the techniques he proposes.. painful, yes but invaluable ;-)

—- cheers atul

Would you like to post a relpy?


This post is a reply to:
Re: Refactoring QueryHits::prepareReadPayload
Hello everybody, It's nice you brought up this topic, Atul! I think some good things can be done in regard to prepareReadPayload(). The original idea was to separate validation of packet (more...)

Follow-ups:
Re: Re: Re: Refactoring QueryHits::prepareReadPayload
No, your changes are fine! Sorry I failed to mention that! Please send me a patch to apply in the mainstream. Another thing I failed to mention in the previous (more...)