Re: Test code review request

Bart Van Assche <[email protected]>
Newsgroups gmane.network.net-snmp.devel
Message-ID <[email protected]>
On 09/13/18 10:55, Bill Fenner wrote:
> I wrote some tests for traps and clientaddr, since there were a bunch of 
> changes between 5.7 and 5.8 in this area.  I did a couple of unusual things:
> 
> 1. I factored a ton of the test code out into a support file, 
> S180trapaddrinfra, since the bulk of the tests were the same.
> 2. I created a little helper, "myip", which uses IO::Socket::IP.  When I 
> pushed this to travis, I found out that IO::Socket::IP isn't "normally" 
> installed.  Is it reasonable to make this a requirement, or should I 
> rewrite the code to use IO::Socket::INET and IO::Socket::INET6?  (In my 
> "normal" work area, IO::Socket::INET6 isn't installed, so it's not clear 
> that this is any better).
> 
> I checked in the code at
> https://github.com/fenner/net-snmp/commit/8572a9d54873f380a2388a354ee85f5eb531c875
> 
> Do these tests look ok to commit as-is or is there some better way to 
> structure a group of similar tests like this?

Is it possible to implement the Perl script such that it detects which 
packages are available and uses the one that is available? 
IO::Socket::INET and IO::Socket::INET6 are available on the AIX system I 
have access to but IO::Socket::IP is not available on that system. On 
the FreeBSD system I have access to IO::Socket::IP is available but none 
of the other socket packages. I do not have sufficient rights to install 
additional packages on these systems.

Thanks,

Bart.


_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.