mozilla-b2g/gaia — pull request #13756 by evhan55 (2013-11-15 20:28:25+00:00)
Title: Bug 936639 - [Messages][Drafts] Create Drafts module/constructor + tests

- Drafts Singleton
- Adds, deletes, clears Draft objects
- Loads and stores Draft objects from storage
- Fetches all Draft objects for a thread id
- Drafts.List object
- Array-list holder for Draft objects
- has readonly accessor for length
- has forEach to run callback on all contained Draft objects
- Draft object
- standalone class to describe fields for a Draft instance
- Tests
- Drafts: unit tests for adding, deletion, clearing, storing, loading, fetching by id
- Draft.List: unit tests for length, forEach
- Draft: no unit tests yet