On 02/12/2015 03:01 PM, Matus Marhefka wrote: > Agree, the more code paths the better.
Alternatively, you could approach it a bit differently - test the actual kernel namespacing functionality using unshare/setns in *kernel*/containers/ and verify that iproute2 uses it in network/iproute/ (or perhaps commands/ip/ ?). The idea being that you don't exactly need to "brute force" test everything everytime - the kernel functionality doesn't change based on what utility uses the unshare() syscall. I (in ltp-unrelated activities) found out that this approach gives the best coverage / time / maintenance ratio. > > Matus Marhefka > > ----- Original Message ----- > From: "Cyril Hrubis" <chru...@suse.cz> > To: "Matus Marhefka" <mmarh...@redhat.com> > Cc: ltp-list@lists.sourceforge.net, "Jan Stancek" <jstan...@redhat.com> > Sent: Thursday, February 12, 2015 12:03:10 PM > Subject: Re: network namespaces tests cleanup > > Hi! >> As network namespaces tests (ltp/testcases/kernel/containers/netns) code is >> a bit messy and it's hard to figure out how return values are passed in the >> code >> I propose to remove all test cases and leave only the ones specified below. > > Sounds good to me. > >> Implementation: >> =============== >> As ip command cannot be used (because of older systems), we can use this >> generic >> functions to create/delete namespace handle: > > Maybe we can do even better, make the testcases work both with unshare > and ip and run them twice (and get TCONF with ip on older systems) so > that we cover ip on newer systems as well. > ------------------------------------------------------------------------------ Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk _______________________________________________ Ltp-list mailing list Ltp-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ltp-list