Closed
Bug 1463702
Opened 7 years ago
Closed 7 years ago
TEST-UNEXPECTED-FAIL | services/common/tests/unit/test_remote_settings_jexl_filters.js and TEST-UNEXPECTED-FAIL | services/common/tests/unit/test_blocklist_clients.js
Categories
(Thunderbird :: General, defect)
Thunderbird
General
Tracking
(Not tracked)
RESOLVED
FIXED
Thunderbird 62.0
People
(Reporter: jorgk-bmo, Unassigned)
References
Details
(Whiteboard: [Thunderbird-testfailure: X all])
EST-UNEXPECTED-FAIL | services/common/tests/unit/test_remote_settings_jexl_filters.js | xpcshell return code: 0
TEST-UNEXPECTED-FAIL | services/common/tests/unit/test_remote_settings_jexl_filters.js | test_returns_entries_where_jexl_is_true - [test_returns_entries_where_jexl_is_true : 71] 0 == 5
TEST-UNEXPECTED-FAIL | services/common/tests/unit/test_blocklist_clients.js | xpcshell return code: 0
TEST-UNEXPECTED-FAIL | services/common/tests/unit/test_blocklist_clients.js | test_entries_are_filtered_when_jexl_filters_is_present - [test_entries_are_filtered_when_jexl_filters_is_present : 293] 2 == 4
M-C last good: 96a6ea5ea3468b4c9e20ff8d9795a7ef13
M-C first bad: d36cd8bdbc5c0df1d1d7a167f5fedb95c3
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=96a6ea5ea3468b4c9e20ff8d9795a7ef13&tochange=d36cd8bdbc5c0df1d1d7a167f5fedb95c3
Looks like
Mathieu Leplatre - Bug 1451031 - Add JEXL filter support in Remote Settings r=mythmon
https://hg.mozilla.org/mozilla-central/rev/13f0a3149181
Mathieu, Gijs: Any hints? These tests are disabled for Android, so should they also be disabled for TB?
Flags: needinfo?(mathieu)
Flags: needinfo?(gijskruitbosch+bugs)
Comment 2•7 years ago
|
||
We had the same error on Android, I disabled them there.
I don't explain why JEXL filters would not resolve to proper values in Thunderbird xpcshell tests.
Maybe because of some missing JavaScript sandboxing features or something?
Jorg, I'm sorry that once again broke your tests.
You can disable them on TB too, like I did here:
https://reviewboard.mozilla.org/r/243392/diff/3-4/
Or we can investigate why the JEXL engine always return undefined on TB.
For the latter, what do obtain when you execute those lines in a console?
```
ChromeUtils.defineModuleGetter(this, "FilterExpressions", "resource://normandy/lib/FilterExpressions.jsm");
FilterExpressions.eval("a == b", {a: 1, b: 1})
.then(r => console.log(r));
```
I suspect the problem to be this:
https://searchfox.org/mozilla-central/rev/eb51d734a8c06ac5973291be9bcc74ed4e999bca/toolkit/components/moz.build#113-114
If that's the case, one possible solution is to extract this FilterExpressions module to toolkit/components/utils like we did for Client environment in Bug 1451033
Flags: needinfo?(mathieu)
Reporter | ||
Comment 3•7 years ago
|
||
Thanks for the quick reply. No problem that those tests fail now, if we address it in a timely manner.
ChromeUtils.defineModuleGetter(this, "FilterExpressions", "resource://normandy/lib/FilterExpressions.jsm");
FilterExpressions.eval("a == b", {a: 1, b: 1}).then(r => console.log(r));
returns
[Exception... "Component is not available" nsresult: "0x80040111 (NS_ERROR_NOT_AVAILABLE)" location: "JS frame :: debugger eval code :: <TOP_LEVEL> :: line 1" data: no]
I'm happy to summit a patch to disable those tests, unless you want to refactor it as indicated. Please let me know. Also, being the "jack of all trades, master of none" in TB, I don't know that JEXL is about. Something useful for TB? If so, the refactoring might be better, if not, we could just switch off the tests.
Comment 4•7 years ago
|
||
Can we move the jexl stuff into toolkit so that it also ships on non-browser apps? That seems like the most straightforward fix here.
Comment 5•7 years ago
|
||
Yes, I can work on that.
Comment 6•7 years ago
|
||
I submitted a patch for Bug 1464006, now waiting for checkin :)
Reporter | ||
Comment 7•7 years ago
|
||
Thanks a lot, I've been watching it. Don't you have Level 3 rights to push it yourself?
Reporter | ||
Comment 8•7 years ago
|
||
Fixed by bug 1464006. Thanks again, Mathieu!
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 62.0
You need to log in
before you can comment on or make changes to this bug.
Description
•