Last Comment Bug 521191 - xpcshell-tests: some unit tests fail with the '-S' option ('strict' & 'werror' on)
: xpcshell-tests: some unit tests fail with the '-S' option ('strict' & 'werror...
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: General (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla1.9.3a1
Assigned To: Jae-Seong Lee-Russo
:
Mentors:
Depends on:
Blocks: 524781
  Show dependency treegraph
 
Reported: 2009-10-08 00:29 PDT by Jae-Seong Lee-Russo
Modified: 2009-12-28 10:28 PST (History)
5 users (show)
bugzillamozillaorg_serge_20140323: in‑testsuite+
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
final-fixed


Attachments
Fix errors (3.57 KB, patch)
2009-10-08 00:30 PDT, Jae-Seong Lee-Russo
no flags Details | Diff | Review
Convert to UNIX newline (3.57 KB, patch)
2009-10-09 04:08 PDT, Jae-Seong Lee-Russo
smontagu: review+
dtownsend: review+
asaf: review+
Details | Diff | Review
Address comment #4 (2.77 KB, patch)
2009-11-02 12:21 PST, Jae-Seong Lee-Russo
no flags Details | Diff | Review

Description Jae-Seong Lee-Russo 2009-10-08 00:29:39 PDT
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.3a1pre) Gecko/20091007 Minefield/3.7a1pre (.NET CLR 3.5.30729)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.3a1pre) Gecko/20091007 Minefield/3.7a1pre (.NET CLR 3.5.30729)

dom/src/json/test/unit/:
TEST-UNEXPECTED-FAIL | c:\mozilla-build\mozilla-central\_tests\xpcshell\json_tes
t\unit\test_decode.js | test failed (with xpcshell return code: 3), see followin
g log:
  >>>>>>>
  json2.js:349: TypeError: function str does not always return a value:
json2.js:349:     }

json2.js:349: ........^

  <<<<<<<

/intl/uconv/tests/unit/test_charset_conversion.js
TEST-UNEXPECTED-FAIL | c:\mozilla-build\mozilla-central\_tests\xpcshell\test_int
l_uconv\unit\test_charset_conversion.js | test failed (with xpcshell return code
: 3), see following log:
  >>>>>>>
  c:/mozilla-build/mozilla-central/_tests/xpcshell/test_intl_uconv/unit/test_cha
rset_conversion.js:202: TypeError: function equal does not always return a value
:
c:/mozilla-build/mozilla-central/_tests/xpcshell/test_intl_uconv/unit/test_chars
et_conversion.js:202: }

c:/mozilla-build/mozilla-central/_tests/xpcshell/test_intl_uconv/unit/test_chars
et_conversion.js:202: .........................^

  <<<<<<<

/modules/libjar/zipwriter/test/unit/test_zippermissions.js
TEST-UNEXPECTED-FAIL | (xpcshell/head.js) | TypeError: assignment to undeclared
variable zipR
uncaught exception: [Exception... "Component returned failure code: 0x80004005 (
NS_ERROR_FAILURE) [nsIFile.remove]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"
location: "JS frame :: c:/mozilla-build/mozilla-central/_tests/xpcshell/test_zip
writer/unit/tail_zipwriter.js :: <TOP_LEVEL> :: line 47"  data: no]

  <<<<<<<

/toolkit/mozapps/extensions/test/unit/test_bug386153.js
TEST-UNEXPECTED-FAIL | c:\mozilla-build\mozilla-central\_tests\xpcshell\test_ext
ensionmanager\unit\test_bug386153.js | test failed (with xpcshell return code: 3
), see following log:
  >>>>>>>
  c:/mozilla-build/mozilla-central/_tests/xpcshell/test_extensionmanager/unit/te
st_bug386153.js:51: TypeError: function findXPI does not always return a value:
c:/mozilla-build/mozilla-central/_tests/xpcshell/test_extensionmanager/unit/test
_bug386153.js:51: }

c:/mozilla-build/mozilla-central/_tests/xpcshell/test_extensionmanager/unit/test
_bug386153.js:51: ........................................^

  <<<<<<<

Reproducible: Always

Steps to Reproduce:
1. Run the xpcshell tests with the '-S' option

Actual Results:  
Failed

Expected Results:  
Passed
Comment 1 Jae-Seong Lee-Russo 2009-10-08 00:30:20 PDT
Created attachment 405228 [details] [diff] [review]
Fix errors
Comment 2 Jae-Seong Lee-Russo 2009-10-09 04:08:39 PDT
Created attachment 405444 [details] [diff] [review]
Convert to UNIX newline
Comment 3 Simon Montagu :smontagu 2009-10-12 21:01:58 PDT
Comment on attachment 405444 [details] [diff] [review]
Convert to UNIX newline

r=smontagu for intl
Comment 4 Mano (::mano, needinfo? for any questions; not reading general bugmail) 2009-10-14 05:26:44 PDT
Comment on attachment 405444 [details] [diff] [review]
Convert to UNIX newline


>diff --git a/toolkit/mozapps/extensions/test/unit/test_bug386153.js b/toolkit/mozapps/extensions/test/unit/test_bug386153.js
>--- a/toolkit/mozapps/extensions/test/unit/test_bug386153.js
>+++ b/toolkit/mozapps/extensions/test/unit/test_bug386153.js
>@@ -43,16 +43,17 @@ const URI_XPINSTALL_CONFIRM_DIALOG = "ch
> 
> // Finds the index of the given xpi in the dialogparamblock strings
> function findXPI(dpb, name) {
>   for (var i = 0; i < 5; i++) {
>     if (dpb.GetString(i * 4 + 1).substr(-(name.length + 1)) == "/" + name)
>       return i * 4;
>   }
>   do_throw(name + " wasn't in the list");
>+  return false;
> }
> 

should be |return 0;|

r=mano for toolkit.
Comment 5 Jonas Sicking (:sicking) 2009-10-29 17:50:39 PDT
Comment on attachment 405444 [details] [diff] [review]
Convert to UNIX newline

I really don't know any of this code. Have you tried checking with the people that wrote the tests?
Comment 6 Jae-Seong Lee-Russo 2009-10-29 18:01:52 PDT
Whom should I ask to review /dom/src/json/test/unit/json2.js?  It seems to be taken from http://www.json.org/json2.js.
Comment 7 Jae-Seong Lee-Russo 2009-11-01 09:20:42 PST
Comment on attachment 405444 [details] [diff] [review]
Convert to UNIX newline

Dave Townsend, can you review the /modules/ part?
Comment 8 Jae-Seong Lee-Russo 2009-11-02 12:21:48 PST
Created attachment 409764 [details] [diff] [review]
Address comment #4
Comment 9 Dão Gottwald [:dao] 2009-11-05 23:41:52 PST
http://hg.mozilla.org/mozilla-central/rev/5c9f28baa878
Comment 10 Nochum Sossonko [:Natch] 2009-12-24 11:17:32 PST
Pushed to 1.9.2: http://hg.mozilla.org/releases/mozilla-1.9.2/rev/a97754ee5736
Comment 11 Nochum Sossonko [:Natch] 2009-12-28 10:28:52 PST
Clearing checkin keywords since these patches don't have 1.9.1 approval. Please request approval on the patches, and once granted, replace the checkin keyword.

Note You need to log in before you can comment on or make changes to this bug.