On 04/16/12 22:49, Saurabh Vyas wrote:
Thanks Brock for quick response, more line ....
On 04/17/12 02:58, Brock Pytlik wrote:
t_pkg_publisher:
Line 454: Don't use the -O option. it's deprecated.
I have modifies the test to use '-g' (instead of '-O')
for quick ref :
+ def test_bug_7141684(self):
+ """Test that pkg(1) client does not traceback if no
publisher
+ configured and we try to get preferred publisher"""
+
+ self.image_create()
+ self.pkg("publisher -P", exit=0)
+
+ self.pkg("set-publisher -g %s test" % self.durl1)
+ self.pkg("install foo")
+ self.pkg("unset-publisher test")
+ self.pkg("publisher -P", exit=0)
BTW I do see use of '-O' with set-publisher at many test cases.
As I am at it, should I file another bug for that that clean up ?
i.e '-O' -- > '-g'
No. Whoever fixes the bug to actually remove the functionality of -O
will have to fix all the test cases. There's just no reason to make that
person's life harder than it already is.
Brock
Other than that. lgtm.
Thanks, I have attached the patch.
If this looks good please if you can integrate this on my behalf.
Thanks again,
~Saurabh
Brock
On 04/16/12 04:27, Saurabh Vyas wrote:
On 04/14/12 02:25, Brock Pytlik wrote:
t_pkg_publisher:
line 436: s/do/does, and watch the 80 character line limit,
"publisher"
looks like it's over to me.
Instead of creating an image with a publisher, I'd prefer you did the
following things:
1) create the image without a publisher (ie, self.image_create())
2) check that publisher -P exits 0
3) add a publisher, install a package from that publisher, unset that
publisher
4) check that publisher -P exits 0 and has the correct output (ie,
none
in this case)
You could also add a check between 2 and 3 where you add and remove a
publisher (essentially what the test is doing today) and then check
the
output of publisher -P.
Thanks Brock for the review & your inputs.
I have enhanced the test to scenarios mentioned by you.
Updated webrev :
https://cr.opensolaris.org/action/browse/pkg/saurabhv/CR-7141684-rev7/webrev/
Please if you can verify.
Test run (for complete test suite) is clean.
Thanks,
~Saurabh
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss