Change in vdsm[master]: utils: move rget to utils

danken at redhat.com danken at redhat.com
Sat Apr 9 18:15:05 UTC 2016


Dan Kenigsberg has posted comments on this change.

Change subject: utils: move rget to utils
......................................................................


Patch Set 2:

(2 comments)

https://gerrit.ovirt.org/#/c/55860/2/tests/utilsTests.py
File tests/utilsTests.py:

Line 341:     def test_unique(self, iterable, unique_items):
Line 342:         self.assertEquals(utils.unique(iterable,), unique_items)
Line 343: 
Line 344:     def test_rget(self):
Line 345:         self.assertEqual(
this assertion would  be more readable if placed in its own method e.g. test_exists() and later a test_missing().
Line 346:             utils.rget({'a': {'b': 'hello'}}, ('a', 'b')),
Line 347:             'hello')
Line 348:         self.assertEqual(
Line 349:             utils.rget({'a': {'b': 'hello'}}, ('a', 'c'), default='bye'),


PS2, Line 346: {'a': {'b': 'hello'}}
a dictionary used twice seems to merit a name.


-- 
To view, visit https://gerrit.ovirt.org/55860
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I93ae32e5ffbfa20a79081aea330e3df3663c3966
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Petr Horáček <phoracek at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Edward Haas <edwardh at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Petr Horáček <phoracek at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list