[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RE: continue on a failing test (dh7)



----------------------------------------
> Date: Wed, 12 Feb 2014 12:37:28 +1100
> From: csmall@debian.org
> To: debian-mentors@lists.debian.org
> Subject: Re: continue on a failing test (dh7)
>
> On Wed, Feb 12, 2014 at 09:20:06AM +0800, Paul Wise wrote:
>> Please don't do that , tests are there for a reason. It is better to
>> fix the problem or fix the test than ignore the test.
> To give an example of why this is important.
>
> procps had a problem where it would fail on certain buildds. At first
> I cursed the buildds, cursed the architectures and their flakyness.
> Nothing I could do would reproduce it, but some buildds would, at
> depressingly semi-regular times, complain.
>
> Eventually the problem was the test was working but made assumptions
> about the system. These are valid assumptions for a normal setup (you
> wouldn't run it like this) however the program shouldn't of crashed
> but complained or exited nicely.
>
> I was *that* close to having a rule in the test setup that basically
> said "if the system is in this state, don't run test". This would of
> masked a real bug in the program; which admittedly not many people will
> ever see, but it shouldn't be there in the first place.
>
> The bug is fixed now, the test will need some adjusting to cater for the
> error message, but that's the correct way it should respond.
>

Oke, 
But then Im going to need a javascript expert. 
I have figured out from the error logs which tests are failing. 

The offending test is this one : 

function testInvalidStrings() {
    // Not really related to locale handling - here we are testing
    // gjs_string_to_utf8() to properly catch things we'll choke
    // on later.

    // Unpaired surrogate
    assertRaises(function() { "\ud800".toLocaleLowerCase(); });
    // Embedded NUL
    assertRaises(function() { "\u0000".toLocaleLowerCase(); });
    // Byte-reversed BOM (an example of a non-character)
    assertRaises(function() { "\ufffe".toLocaleLowerCase(); });
}

One of the test gives undefined where it schould be given a exception. 
The whole file can be found here : https://github.com/linuxmint/cjs/blob/master/test/js/testLocale.js

if needed I can give the error logs. 

Roelof 		 	   		  

Reply to: