BIND 10 #2574: improve b10-loadzone on progress/result report

BIND 10 Development do-not-reply at isc.org
Mon Jan 21 16:30:57 UTC 2013


#2574: improve b10-loadzone on progress/result report
-------------------------------------+-------------------------------------
            Reporter:  jinmei        |                        Owner:
                Type:  task          |  jinmei
            Priority:  medium        |                       Status:
           Component:  loadzone      |  reviewing
            Keywords:                |                    Milestone:
           Sensitive:  0             |  Sprint-20130122
         Sub-Project:  DNS           |                   Resolution:
Estimated Difficulty:  2             |                 CVSS Scoring:
         Total Hours:  0             |              Defect Severity:  N/A
                                     |  Feature Depending on Ticket:
                                     |  loadzone-ng
                                     |          Add Hours to Ticket:  0
                                     |                    Internal?:  0
-------------------------------------+-------------------------------------

Comment (by jinmei):

 Thanks for the review.

 Replying to [comment:6 jelte]:
 > In general it looks fine.
 >
 > One thing that seems a bit weird is that the _get_time callable is only
 used in one place (while time.time() is also called directly a number of
 times), and even for tests it shouldn't even be necessary (but makes
 cleanup easier). But no real strong opinion on that.

 Do you mean we could override loadzone.time.time in tests and revert
 it at `tearDown`?  If so, yes, we could.  I don't have a strong
 opinion with either way, but since that means I don't see the need for
 updating the current code, I propose keeping it with some additional
 comment
 like this:
 {{{#!python
         # This one will be used in (rare) cases where we want to allow
 tests to
         # fake time.time()
         self._get_time = time.time
 }}}
 just to clarify we don't use this trick for all calls to time.time().

-- 
Ticket URL: <http://bind10.isc.org/ticket/2574#comment:8>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list