Closed
Bug 1280769
Opened 8 years ago
Closed 8 years ago
Add Hyphenation Dictionary as separate kind in downloadable content
Categories
(Firefox for Android Graveyard :: General, defect)
Firefox for Android Graveyard
General
Tracking
(firefox50 fixed)
RESOLVED
FIXED
Firefox 50
Tracking | Status | |
---|---|---|
firefox50 | --- | fixed |
People
(Reporter: k.krish, Assigned: k.krish, Mentored)
References
Details
Attachments
(1 file)
As a part of Bug 1095719, add "KIND_HYPHENATION_DICTIONARY" as a separate kind in Downloadable Content.
Assignee: nobody → k.krish
Blocks: 1276589, downloadable-hyphenation-dicts
Summary: Add Hyphenation Dictionary as separate kind in download content → Add Hyphenation Dictionary as separate kind in downloadable content
Review commit: https://reviewboard.mozilla.org/r/59562/diff/#index_header See other reviews: https://reviewboard.mozilla.org/r/59562/
Attachment #8763337 -
Flags: review?(s.kaspari)
Comment on attachment 8763337 [details] Bug 1280769 - Add Hyphenation Dictionary as separate kind Review request updated; see interdiff: https://reviewboard.mozilla.org/r/59562/diff/1-2/
Comment 3•8 years ago
|
||
Comment on attachment 8763337 [details] Bug 1280769 - Add Hyphenation Dictionary as separate kind https://reviewboard.mozilla.org/r/59562/#review56700 ::: mobile/android/base/java/org/mozilla/gecko/dlc/catalog/DownloadContent.java:140 (Diff revision 2) > public boolean isAssetArchive() { > - return TYPE_ASSET_ARCHIVE.equals(type); > + return (TYPE_ASSET_ARCHIVE.equals(type) && isKnownContent()); > } Oh, sorry for the confusion. In the other bug I meant we could call isAssetArchive() from within isKnownContent(). Not the other way around. isAssetArchive() should just do what the name says. But a content is only known if it has a known type (asset archive) and kind (font or hyphenation dictionary).
Attachment #8763337 -
Flags: review?(s.kaspari)
Comment on attachment 8763337 [details] Bug 1280769 - Add Hyphenation Dictionary as separate kind Review request updated; see interdiff: https://reviewboard.mozilla.org/r/59562/diff/2-3/
Attachment #8763337 -
Flags: review?(s.kaspari)
https://reviewboard.mozilla.org/r/59562/#review56700 > Oh, sorry for the confusion. In the other bug I meant we could call isAssetArchive() from within isKnownContent(). Not the other way around. isAssetArchive() should just do what the name says. But a content is only known if it has a known type (asset archive) and kind (font or hyphenation dictionary). Oops. Sorry for the mixup. I've updated the code.
Comment 6•8 years ago
|
||
This is looking good. Did you already test this on try? Maybe you can look into extending TestDownloadAction too. Just some very simple tests for isHyphenationDictionary() and isKnownContent() would be nice!
Not yet. Shall I write those tests and ship it with this bug or a separate one? If we are going to have a separate bug I will trigger a try build for this bug :)
Comment 8•8 years ago
|
||
As you like. It would be nice to land the tests with the code. However if you want to take some more time for them, then let's run the current code on try and land this ahead. Right now this code is not used yet, so the risk is low.
Comment on attachment 8763337 [details] Bug 1280769 - Add Hyphenation Dictionary as separate kind Review request updated; see interdiff: https://reviewboard.mozilla.org/r/59562/diff/3-4/
Assignee | ||
Comment 10•8 years ago
|
||
I have extended the TestDownloadAction class. I have written test cases for both isHyphenationDictionary and isKnownContent with few important scenarios. :)
Comment 11•8 years ago
|
||
Comment on attachment 8763337 [details] Bug 1280769 - Add Hyphenation Dictionary as separate kind https://reviewboard.mozilla.org/r/59562/#review56740 Great test! :) ::: mobile/android/base/java/org/mozilla/gecko/dlc/catalog/DownloadContent.java:139 (Diff revision 4) > + /** > + *Checks whether the content to be downloaded is a known content. > + *Currently it checks whether the type is "Asset Archive" and is of kind > + *"Font" or "Hyphenation Dictionary". > + */ > + public boolean isKnownContent() { return ((isFont() || isHyphenationDictionary()) && isAssetArchive()); } nit: Move the return statement to its own line: ... isKnownContent() { return ... }
Attachment #8763337 -
Flags: review?(s.kaspari) → review+
Assignee | ||
Comment 12•8 years ago
|
||
Comment on attachment 8763337 [details] Bug 1280769 - Add Hyphenation Dictionary as separate kind Review request updated; see interdiff: https://reviewboard.mozilla.org/r/59562/diff/4-5/
Assignee | ||
Comment 13•8 years ago
|
||
Shall I push this patch to try?
Comment 14•8 years ago
|
||
(In reply to k.krish from comment #13) > Shall I push this patch to try? Yeah, I think we could land this part after a successful try run.. right?
Assignee | ||
Comment 15•8 years ago
|
||
Comment on attachment 8763337 [details] Bug 1280769 - Add Hyphenation Dictionary as separate kind Review request updated; see interdiff: https://reviewboard.mozilla.org/r/59562/diff/5-6/
Assignee | ||
Comment 16•8 years ago
|
||
Try Results https://treeherder.mozilla.org/#/jobs?repo=try&revision=885e1cd38275
Assignee | ||
Comment 17•8 years ago
|
||
Yes we can land this patch now as try results have succeeded.
Keywords: checkin-needed
Comment 18•8 years ago
|
||
Pushed by ryanvm@gmail.com: https://hg.mozilla.org/integration/fx-team/rev/0f427b2d15eb Add Hyphenation Dictionary as separate kind. r=sebastian
Keywords: checkin-needed
Comment 19•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/0f427b2d15eb
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox50:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 50
Updated•3 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•