BIND 10 #2353: write tests for all methods of Bob
BIND 10 Development
do-not-reply at isc.org
Wed Oct 10 18:36:55 UTC 2012
#2353: write tests for all methods of Bob
-------------------------------------+-------------------------------------
Reporter: | Owner:
jinmei | Status: new
Type: | Milestone: Next-Sprint-
defect | Proposed
Priority: | Resolution:
medium | Sensitive: 0
Component: Boss | Sub-Project: DNS
of BIND | Estimated Difficulty: 0
Keywords: | Total Hours: 0
Defect Severity: N/A |
Feature Depending on Ticket: |
Add Hours to Ticket: 0 |
Internal?: 0 |
-------------------------------------+-------------------------------------
Description changed by jinmei:
Old description:
> As mentioned in http://bind10.isc.org/ticket/2244#comment:11,
> the `Bob` class is currently only poorly tested (there are several
> methods that have no tests). It's not good, particularly because
> it has very important roles.
>
> I guess it's partly because of a historical reason (the implementation
> has been there since we were not strict about writing tests) and
> partly because it relies on some low level features like process
> handling. Obviously the first one cannot be an excuse, and I don't
> think it a very difficult issue either, since it's quite easy to steal
> such low layer interfaces.
>
> So, in this ticket I propose writing tests for all untested methods of
> the `Bob` class. For the scope of this ticket it's probably okay to
> just provide some normal and major error cases (ignoring tricky corner
> cases for now).
>
> On top of that I'd suggest refactoring the class to improve
> readability. It's now a very big and monolithic class consisting of
> several hundresds of lines. I guess we should consider extracting
> some of the responsibility to some helper classes or other refactoring
> techniques to improve overall readability. But that would be the topic
> of a separate ticket.
New description:
As mentioned in http://bind10.isc.org/ticket/2244#comment:11,
the `Bob` class is currently only poorly tested (there are several
methods that have no tests). It's not good, particularly because
it has very important roles.
I guess it's partly because of a historical reason (the implementation
has been there since we were not strict about writing tests) and
partly because it relies on some low level features like process
handling. Obviously the first one cannot be an excuse, and I don't
think the second one a very difficult issue either, since it's quite
easy to steal such low layer interfaces.
So, in this ticket I propose writing tests for all untested methods of
the `Bob` class. For the scope of this ticket it's probably okay to
just provide some normal and major error cases (ignoring tricky corner
cases for now).
On top of that I'd suggest refactoring the class to improve
readability. It's now a very big and monolithic class consisting of
several hundresds of lines. I guess we should consider extracting
some of the responsibility to some helper classes or other refactoring
techniques to improve overall readability. But that would be the topic
of a separate ticket.
--
--
Ticket URL: <http://bind10.isc.org/ticket/2353#comment:1>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development
More information about the bind10-tickets
mailing list