[nanomsg] Re: Interception hooks for testing.

  • From: Jeff Archer <jsarcher@xxxxxxxxxxxxxxxxxxxxxx>
  • To: nanomsg@xxxxxxxxxxxxx
  • Date: Fri, 4 Oct 2013 12:10:52 -0400

On Fri, Oct 4, 2013 at 11:08 AM, Martin Sustrik <sustrik@xxxxxxxxxx> wrote:

> Hi all,
>
>
>  On Fri, Oct 4, 2013 at 3:34 PM, Jeff Archer
>> <jsarcher@nanotronicsimaging.**com <jsarcher@xxxxxxxxxxxxxxxxxxxxxx>>
>> wrote:
>>
>>> I disagree.  The code could be conditionally included into DEBUG builds
>>> only
>>> and would allow nanomsg to be uniformly tested on all platforms without
>>> requiring outside utility that may not be available on some platforms.  I
>>> believe this level of defiend and supported by the project is a
>>> requirement
>>> for an open source project to be truly successful.
>>>
>>
> nanomsg library itself should not try to simulate disconnects, slowdowns
> etc. If it done so, the test results wouldn't be very credible. "nanomsg is
> able to survive when it partitions itself" is less convincing than "nanomsg
> is able to survive a network partition".
>
> What is really being discussed here IMO is integration testing (as opposed
> to the unit tests we have in the project now). The problem with integration
> testing is that it cannot be made fully automatic ("make integration-tests"
> or similar). It requires knowledge of the test environment network,
> deploying individual components, tuning the network (e.g. via ip tables)
> etc.
>
> What we can do is run integration tests on regular basis in our test
> environment. However, it's not a trivial amount of work, so help would be
> needed. The first step would be to create a separate "nanomsg-integration"
> project, populate it with integration tests, write down the procedures for
> testing (so that anyone can reproduce it). Once done, the second step would
> be to actually set it up in our test env.
>
> Btw, sorry for the delays. I am stranded on a different continent with my
> laptop broken :)
>
> Martin
>
>
I was think of this more from a unit testing standpoint.  To make it
convenient to get 100% code path testing on each platform.  Not necessarily
in place of other testing.

Other related posts: