xpcshell-tests: some unit tests fail with the '-S' option ('strict' & 'werror' on)

RESOLVED FIXED in mozilla1.9.3a1

Status

()

Core
General
RESOLVED FIXED
8 years ago
8 years ago

People

(Reporter: Jae-Seong Lee-Russo, Assigned: Jae-Seong Lee-Russo)

Tracking

(Blocks: 1 bug)

Trunk
mozilla1.9.3a1
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(status1.9.2 final-fixed)

Details

Attachments

(1 attachment, 2 obsolete attachments)

(Assignee)

Description

8 years ago
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
(Assignee)

Comment 1

8 years ago
Created attachment 405228 [details] [diff] [review]
Fix errors
(Assignee)

Updated

8 years ago
Version: unspecified → Trunk
(Assignee)

Updated

8 years ago
Attachment #405228 - Flags: review?(tglek)
Attachment #405228 - Flags: review?(smontagu)
Attachment #405228 - Flags: review?(mano)
Attachment #405228 - Flags: review?(jonas)
Assignee: nobody → lusian
Status: UNCONFIRMED → NEW
Ever confirmed: true
Severity: trivial → normal
Component: General → General
Product: Testing → Core
QA Contact: general → general
(Assignee)

Comment 2

8 years ago
Created attachment 405444 [details] [diff] [review]
Convert to UNIX newline
Attachment #405228 - Attachment is obsolete: true
Attachment #405444 - Flags: review?(tglek)
Attachment #405444 - Flags: review?(smontagu)
Attachment #405444 - Flags: review?(mano)
Attachment #405444 - Flags: review?(jonas)
Attachment #405228 - Flags: review?(tglek)
Attachment #405228 - Flags: review?(smontagu)
Attachment #405228 - Flags: review?(mano)
Attachment #405228 - Flags: review?(jonas)
Comment on attachment 405444 [details] [diff] [review]
Convert to UNIX newline

r=smontagu for intl
Attachment #405444 - Flags: review?(smontagu) → review+
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.
Attachment #405444 - Flags: review?(mano) → review+
(Assignee)

Updated

8 years ago
Blocks: 524781
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?
Attachment #405444 - Flags: review?(jonas)
(Assignee)

Comment 6

8 years ago
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.
(Assignee)

Comment 7

8 years ago
Comment on attachment 405444 [details] [diff] [review]
Convert to UNIX newline

Dave Townsend, can you review the /modules/ part?
Attachment #405444 - Flags: review?(tglek) → review?(dtownsend)
Attachment #405444 - Flags: review?(dtownsend) → review+
(Assignee)

Comment 8

8 years ago
Created attachment 409764 [details] [diff] [review]
Address comment #4
Attachment #405444 - Attachment is obsolete: true
(Assignee)

Updated

8 years ago
Keywords: checkin-needed
http://hg.mozilla.org/mozilla-central/rev/5c9f28baa878
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a1
Flags: in-testsuite+
Keywords: checkin-needed
Whiteboard: [c-n: m-1.9.2, m-1.9.1]
Pushed to 1.9.2: http://hg.mozilla.org/releases/mozilla-1.9.2/rev/a97754ee5736
status1.9.2: --- → final-fixed
Whiteboard: [c-n: m-1.9.2, m-1.9.1] → [c-n: m-1.9.1]
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.
Keywords: checkin-needed
Whiteboard: [c-n: m-1.9.1]
You need to log in before you can comment on or make changes to this bug.