gen_template.pl generates busted chrome tests because its path to SimpleTest is wrong

RESOLVED FIXED in mozilla33

Status

RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: Gijs, Assigned: Gijs)

Tracking

unspecified
mozilla33
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
Existing tests use:

chrome://mochikit/content/tests/SimpleTest/SimpleTest.js

but the template ( http://mxr.mozilla.org/mozilla-central/source/testing/mochitest/static/xul.template.txt ) generates:

9   <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"/>

which 404s.
(Assignee)

Comment 1

5 years ago
Created attachment 8436893 [details] [diff] [review]
mochitest chrome template uses broken path to SimpleTest.js,
Attachment #8436893 - Flags: review?(jmaher)
Comment on attachment 8436893 [details] [diff] [review]
mochitest chrome template uses broken path to SimpleTest.js,

Review of attachment 8436893 [details] [diff] [review]:
-----------------------------------------------------------------

thanks. on an unrelated note, do people still use these templates?  I was under the impression it was more of a copy/paste from a similar test.
Attachment #8436893 - Flags: review?(jmaher) → review+
I don't think I've ever used one of these templates, they're clearly not well-supported.
I think we'd be better-served just having a simple example test of each kind that developers could copy and paste. Having them be real example tests means they'd be actually run in production and would be up-to-date by necessity.
(Assignee)

Comment 5

5 years ago
(In reply to Ted Mielczarek [:ted.mielczarek] from comment #4)
> I think we'd be better-served just having a simple example test of each kind
> that developers could copy and paste. Having them be real example tests
> means they'd be actually run in production and would be up-to-date by
> necessity.

I would agree, but right now, this is still the recommended way (per docs) of creating new tests.

I'd like to just land this, and file a followup bug to add simple sample tests, and a mach command to do what gen_template.pl does now based on those sample tests. I don't know if/when I will have time to do that, though.

Does that sound OK?
Flags: needinfo?(ted)
That's fine. No point in blocking an already-written patch on a better solution.
Flags: needinfo?(ted)
(Assignee)

Comment 7

5 years ago
remote:   https://hg.mozilla.org/integration/fx-team/rev/c0a859335b41
Status: NEW → ASSIGNED
Whiteboard: [fixed-in-fx-team]
(Assignee)

Comment 8

5 years ago
Filed bug 1022683.
https://hg.mozilla.org/mozilla-central/rev/c0a859335b41
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → mozilla33
You need to log in before you can comment on or make changes to this bug.