Closed
Bug 1074640
Opened 11 years ago
Closed 11 years ago
More tests for bookmarks
Categories
(Cloud Services Graveyard :: cloudSync, defect)
Cloud Services Graveyard
cloudSync
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla35
People
(Reporter: akligman, Assigned: akligman)
Details
Attachments
(1 file, 1 obsolete file)
|
3.21 KB,
patch
|
akligman
:
review+
|
Details | Diff | Splinter Review |
Add some additional xpcshell tests for bookmarks.
| Assignee | ||
Comment 1•11 years ago
|
||
| Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
| Assignee | ||
Updated•11 years ago
|
Attachment #8497303 -
Flags: review?(rnewman)
Updated•11 years ago
|
Status: NEW → ASSIGNED
OS: Linux → All
Hardware: x86_64 → All
Comment 3•11 years ago
|
||
Comment on attachment 8497303 [details] [diff] [review]
0001-CLOUDSYNC-more-tests.patch
Review of attachment 8497303 [details] [diff] [review]:
-----------------------------------------------------------------
::: services/cloudsync/tests/xpcshell/test_bookmarks.js
@@ +13,5 @@
> let rootFolder = yield CloudSync().bookmarks.getRootFolder("TEST");
> + ok(rootFolder.id, "root folder id is ok");
> +
> + let items = [
> + {"id":"G_UL4ZhOyX8m","type":rootFolder.BOOKMARK,"title":"reddit: the front page of the internet 1","uri":"http://www.reddit.com",index:2},
Could you make sure there's non-ASCII in here?
@@ +14,5 @@
> + ok(rootFolder.id, "root folder id is ok");
> +
> + let items = [
> + {"id":"G_UL4ZhOyX8m","type":rootFolder.BOOKMARK,"title":"reddit: the front page of the internet 1","uri":"http://www.reddit.com",index:2},
> + {"id":"G_UL4ZhOyX8n","type":rootFolder.BOOKMARK,"title":"reddit: the front page of the internet 2","uri":"http://www.reddit.com?1",index:1},
Nit: alignment.
@@ +19,5 @@
> + ];
> + yield rootFolder.mergeRemoteItems(items);
> +
> + let localItems = yield rootFolder.getLocalItems();
> + equal(Object.keys(localItems).length, items.length, "found merged items");
Test contents?
@@ +30,5 @@
> + ok(rootFolder.id, "root folder id is ok");
> +
> + let items = [
> + {"id":"G_UL4ZhOyX8m","type":rootFolder.BOOKMARK,"title":"reddit: the front page of the internet 1","uri":"http://www.reddit.com",index:2},
> + {"id":"G_UL4ZhOyX8n","type":rootFolder.BOOKMARK,parent:"G_UL4ZhOyX8x","title":"reddit: the front page of the internet 2","uri":"http://www.reddit.com/?1",index:1},
Alignment again.
@@ +42,5 @@
> + localItems.forEach(function(item) {
> + ok(item.id == "G_UL4ZhOyX8m" ||
> + item.id == "G_UL4ZhOyX8n" ||
> + item.id == "G_UL4ZhOyX8x");
> + if(item.id == "G_UL4ZhOyX8n") {
Nit: "if ("
@@ +60,5 @@
> + equal(bookmark.title, "reddit: the front page of the internet 2");
> + equal(bookmark.index, 0);
> + equal(bookmark.uri, "http://www.reddit.com/?1");
> +
> + yield CloudSync().bookmarks.deleteRootFolder("TEST");
This won't run if the earlier code throws, right? Put this in a cleanup function (for toplevel; IIRC, that's do_register_cleanup in xpcshell) or finally.
Attachment #8497303 -
Flags: review?(rnewman) → review+
| Assignee | ||
Comment 4•11 years ago
|
||
Attachment #8497303 -
Attachment is obsolete: true
Attachment #8497761 -
Flags: review+
| Assignee | ||
Comment 5•11 years ago
|
||
| Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
| Assignee | ||
Comment 6•11 years ago
|
||
Note that this is blocking an uplift to Aurora (bug#993584).
Comment 7•11 years ago
|
||
Alan: when things are urgent, it's best not to rely on checkin-needed. Try pinging a sheriff in #developers, or finding someone you know has commit access.
(I'm afk for the next few hours, else I'd do it.)
| Assignee | ||
Comment 8•11 years ago
|
||
Richard: Thanks, I've pinged a sheriff.
Keywords: checkin-needed
Whiteboard: [fixed-in-fx-team]
Comment 10•11 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → mozilla35
Updated•2 years ago
|
Product: Cloud Services → Cloud Services Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•