Comment 12 for bug 1259292

Revision history for this message
Clint Byrum (clint-fewbar) wrote : Re: [Bug 1259292] Re: Some tests use assertEqual(observed, expected) , the argument order is wrong

Excerpts from John Griffith's message of 2014-02-25 23:47:08 UTC:
> I don't see much value in this and honestly it seems rather silly to go
> through the effort. It happens that testtools does in fact use the
> ordering you prefer in their examples, however many other frameworks
> document using the exact opposite. In reality I don't see what it
> really matters or what the benefit is.
>
> I don't speak for other projects but from Cinder's perspective this is
> not something I would want to see proposed for this stage of the
> release. If you want to go through and change this when Juno opens up
> and propose for Cinder at that time I suppose that's fine, but right now
> I'd rather people didn't spend time reviewing changes like this.
>

Hi John. The trouble happens when the tests fail, and it tells you the
opposite of reality. This isn't about the examples, it is about the text
of the failure report.

Unit tests are meant to help debug situations where a developer has
misunderstood complex inner workings of things. So if we also tell
them that we observed what they expect in the test, and expect what was
observed and what was also wrong, we are just decreasing the value of
the unit tests.

I agree that early in dev cycles is a better time for low priority issues,
and this is a low priority, but it is not a low value.