add mock data to result draft
authorRay Lin <ralin@mozilla.com>
Mon, 20 Feb 2017 14:38:58 +0800
changeset 565634 9a03506fa2f40022ec35e997afce28a591e74e2c
parent 565531 20dff607fb88ee69135a280bbb7f32df75a86237
child 565635 5d5407a1407a3735897282a67d6f10022e09ad28
child 565664 c93bb2a67daef1442e28af62423bf6308184aaa3
child 565665 c5eb637f0e5e3ad5861b231fd4126698c9fbc15f
push id54932
push userbmo:ralin@mozilla.com
push dateThu, 20 Apr 2017 06:28:05 +0000
milestone55.0a1
add mock data to result MozReview-Commit-ID: HtrsgGDytwh
browser/extensions/formautofill/ProfileStorage.jsm
--- a/browser/extensions/formautofill/ProfileStorage.jsm
+++ b/browser/extensions/formautofill/ProfileStorage.jsm
@@ -69,29 +69,35 @@ const VALID_FIELDS = [
   "address-level1",
   "postal-code",
   "country",
   "tel",
   "email",
 ];
 
 // TODO: Remove this once we can add profile from preference.
-const MOCK_MODE = false;
+const MOCK_MODE = true;
 const MOCK_STORAGE = [{
-  guid: "test-guid-1",
-  organization: "Sesame Street",
-  "street-address": "123 Sesame Street.",
-  tel: "1-345-345-3456",
+  organization: "World Wide Web Consortium",
+  "street-address": "32 Vassar Street\nMIT Room 32-G524",
+  "address-level2": "Cambridge",
+  "address-level1": "MA",
+  "postal-code": "02139",
+  country: "US",
+  tel: "+1 617 253 5702",
+  email: "timbl@w3.org",
 }, {
-  guid: "test-guid-2",
-  organization: "Mozilla",
-  "street-address": "331 E. Evelyn Avenue",
-  tel: "1-650-903-0800",
+  "street-address": "Some Address",
+  country: "US",
+}, {
+  "street-address": "Other Address",
+  "postal-code": "12345",
 }];
 
+
 function ProfileStorage(path) {
   this._path = path;
 }
 
 ProfileStorage.prototype = {
   // These fields are defined internally for each profile.
   INTERNAL_FIELDS:
     ["guid", "timeCreated", "timeLastUsed", "timeLastModified", "timesUsed"],