Bug 1058101 - Move dom/src/json/ into dom/. r=mccr8
authorBirunthan Mohanathas <birunthan@mohanathas.com>
Sat, 30 Aug 2014 21:43:45 -0700
changeset 224377 73bbfa0bebc7c8b506acdee6a03dda61dd0e7fb5
parent 224376 eecdde427cb7922c0c726586983f6d786f2413f0
child 224378 3795c155428def96670411744bf21e59ab141612
push id3979
push userraliiev@mozilla.com
push dateMon, 13 Oct 2014 16:35:44 +0000
treeherdermozilla-beta@30f2cc610691 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmccr8
bugs1058101
milestone34.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1058101 - Move dom/src/json/ into dom/. r=mccr8
dom/json/moz.build
dom/json/nsJSON.cpp
dom/json/nsJSON.h
dom/json/test/mochitest.ini
dom/json/test/test_json.html
dom/json/test/unit/decodeFromStream-01.json
dom/json/test/unit/decodeFromStream-small.json
dom/json/test/unit/test_decodeFromStream.js
dom/json/test/unit/test_decode_long_input.js
dom/json/test/unit/test_encode.js
dom/json/test/unit/xpcshell.ini
dom/moz.build
dom/src/json/moz.build
dom/src/json/nsJSON.cpp
dom/src/json/nsJSON.h
dom/src/json/test/mochitest.ini
dom/src/json/test/test_json.html
dom/src/json/test/unit/decodeFromStream-01.json
dom/src/json/test/unit/decodeFromStream-small.json
dom/src/json/test/unit/test_decodeFromStream.js
dom/src/json/test/unit/test_decode_long_input.js
dom/src/json/test/unit/test_encode.js
dom/src/json/test/unit/xpcshell.ini
dom/src/moz.build
js/src/tests/ecma_5/JSON/parse-crockford-01.js
js/src/tests/ecma_5/JSON/parse-octal-syntax-error.js
js/src/tests/ecma_5/JSON/parse-primitives.js
js/src/tests/ecma_5/JSON/parse-reviver.js
js/src/tests/ecma_5/JSON/parse-syntax-errors-01.js
js/src/tests/ecma_5/JSON/parse-syntax-errors-02.js
js/src/tests/ecma_5/JSON/parse.js
js/src/tests/ecma_5/JSON/stringify-dropping-elements.js
js/src/tests/ecma_5/JSON/stringify-primitives.js
js/src/tests/ecma_5/JSON/stringify-replacer.js
js/src/tests/ecma_5/JSON/stringify.js
layout/build/moz.build
testing/xpcshell/xpcshell_android.ini
rename from dom/src/json/moz.build
rename to dom/json/moz.build
rename from dom/src/json/nsJSON.cpp
rename to dom/json/nsJSON.cpp
rename from dom/src/json/nsJSON.h
rename to dom/json/nsJSON.h
rename from dom/src/json/test/mochitest.ini
rename to dom/json/test/mochitest.ini
rename from dom/src/json/test/test_json.html
rename to dom/json/test/test_json.html
rename from dom/src/json/test/unit/decodeFromStream-01.json
rename to dom/json/test/unit/decodeFromStream-01.json
rename from dom/src/json/test/unit/decodeFromStream-small.json
rename to dom/json/test/unit/decodeFromStream-small.json
rename from dom/src/json/test/unit/test_decodeFromStream.js
rename to dom/json/test/unit/test_decodeFromStream.js
rename from dom/src/json/test/unit/test_decode_long_input.js
rename to dom/json/test/unit/test_decode_long_input.js
rename from dom/src/json/test/unit/test_encode.js
rename to dom/json/test/unit/test_encode.js
rename from dom/src/json/test/unit/xpcshell.ini
rename to dom/json/test/unit/xpcshell.ini
--- a/dom/moz.build
+++ b/dom/moz.build
@@ -52,16 +52,17 @@ DIRS += [
     'devicestorage',
     'encoding',
     'events',
     'fetch',
     'filehandle',
     'filesystem',
     'fmradio',
     'geolocation',
+    'json',
     'asmjscache',
     'mathml',
     'media',
     'messages',
     'power',
     'push',
     'quota',
     'settings',
--- a/dom/src/moz.build
+++ b/dom/src/moz.build
@@ -3,13 +3,12 @@
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 DIRS += [
     'jsurl',
     'storage',
     'offline',
-    'json',
     'notification',
 ]
 
 JAR_MANIFESTS += ['jar.mn']
--- a/js/src/tests/ecma_5/JSON/parse-crockford-01.js
+++ b/js/src/tests/ecma_5/JSON/parse-crockford-01.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_decode.js
-
 var str =
   '[\n' +
   '    "JSON Test Pattern pass1",\n' +
   '    {"object with 1 member":["array with 1 element"]},\n' +
   '    {},\n' +
   '    [],\n' +
   '    -42,\n' +
   '    true,\n' +
--- a/js/src/tests/ecma_5/JSON/parse-octal-syntax-error.js
+++ b/js/src/tests/ecma_5/JSON/parse-octal-syntax-error.js
@@ -1,11 +1,8 @@
-// Ported from dom/src/json/test/unit/test_decode.js and
-// dom/src/json/test/unit/fail13.json
-
 testJSON('{"Numbers cannot have leading zeroes": 013}', true);
 
 /******************************************************************************/
 
 if (typeof reportCompare === "function")
   reportCompare(true, true);
 
 print("Tests complete");
--- a/js/src/tests/ecma_5/JSON/parse-primitives.js
+++ b/js/src/tests/ecma_5/JSON/parse-primitives.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_decode_primitives.js
-
 var x;
 
 // check an empty object, just for sanity
 var emptyObject = "{}";
 x = JSON.parse(emptyObject);
 assertEq(typeof x, "object");
 assertEq(x instanceof Object, true);
 
--- a/js/src/tests/ecma_5/JSON/parse-reviver.js
+++ b/js/src/tests/ecma_5/JSON/parse-reviver.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_reviver.js
-
 function doubler(k, v)
 {
   assertEq(typeof k, "string");
 
   if (typeof v == "number")
     return 2 * v;
 
   return v;
--- a/js/src/tests/ecma_5/JSON/parse-syntax-errors-01.js
+++ b/js/src/tests/ecma_5/JSON/parse-syntax-errors-01.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_syntax_errors.js
-
 testJSON("{}...", true);
 testJSON('{"foo": truBBBB}', true);
 testJSON('{foo: truBBBB}', true);
 testJSON('{"foo": undefined}', true);
 testJSON('{"foo": ]', true);
 testJSON('{"foo', true);
 
 /******************************************************************************/
--- a/js/src/tests/ecma_5/JSON/parse-syntax-errors-02.js
+++ b/js/src/tests/ecma_5/JSON/parse-syntax-errors-02.js
@@ -1,11 +1,8 @@
-// Ported from dom/src/json/test/unit/test_decode.js and
-// dom/src/json/test/unit/fail[1 to 34, minus 13].json
-
 testJSON('"Unterminated string literal', true);
 testJSON('["Unclosed array"', true);
 testJSON('{unquoted_key: "keys must be quoted"}', true);
 testJSON('["extra comma",]', true);
 testJSON('["double extra comma",,]', true);
 testJSON('[   , "<-- missing value"]', true);
 testJSON('["Comma after the close"],', true);
 testJSON('["Extra close"]]', true);
--- a/js/src/tests/ecma_5/JSON/parse.js
+++ b/js/src/tests/ecma_5/JSON/parse.js
@@ -1,11 +1,8 @@
-// Ported from dom/src/json/test/unit/test_wrappers.js and
-// dom/src/json/test/unit/test_decode.js
-
 function assertIsObject(x)
 {
   assertEq(typeof x, "object");
   assertEq(x instanceof Object, true);
 }
 
 function assertIsArray(x)
 {
--- a/js/src/tests/ecma_5/JSON/stringify-dropping-elements.js
+++ b/js/src/tests/ecma_5/JSON/stringify-dropping-elements.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_dropping_elements_in_stringify.js
-
 assertEq(JSON.stringify({foo: 123}),
          '{"foo":123}');
 assertEq(JSON.stringify({foo: 123, bar: function () {}}),
          '{"foo":123}');
 assertEq(JSON.stringify({foo: 123, bar: function () {}, baz: 123}),
          '{"foo":123,"baz":123}');
 
 assertEq(JSON.stringify([123]),
--- a/js/src/tests/ecma_5/JSON/stringify-primitives.js
+++ b/js/src/tests/ecma_5/JSON/stringify-primitives.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_encode_primitives.js
-
 // sanity
 var x = JSON.stringify({});
 assertEq(x, "{}");
 
 // booleans and null
 x = JSON.stringify(true);
 assertEq(x, "true");
 
--- a/js/src/tests/ecma_5/JSON/stringify-replacer.js
+++ b/js/src/tests/ecma_5/JSON/stringify-replacer.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_replacer.js
-
 /**
  * These return* functions are used by the
  * replacer tests taken from bug 512447
  */
 function returnObjectFor1(k, v)
 {
   if (k == "1")
     return {};
--- a/js/src/tests/ecma_5/JSON/stringify.js
+++ b/js/src/tests/ecma_5/JSON/stringify.js
@@ -1,10 +1,8 @@
-// Ported from dom/src/json/test/unit/test_wrappers.js
-
 function assertStringify(v, expect)
 {
   assertEq(JSON.stringify(v), expect);
 }
 
 assertStringify({}, "{}");
 assertStringify([], "[]");
 assertStringify({"foo":"bar"}, '{"foo":"bar"}');
--- a/layout/build/moz.build
+++ b/layout/build/moz.build
@@ -46,19 +46,19 @@ LOCAL_INCLUDES += [
     '/content/xul/templates/src',
     '/docshell/base',
     '/dom/audiochannel',
     '/dom/base',
     '/dom/camera',
     '/dom/canvas',
     '/dom/filesystem',
     '/dom/geolocation',
+    '/dom/json',
     '/dom/media',
     '/dom/speakermanager',
-    '/dom/src/json',
     '/dom/src/jsurl',
     '/dom/src/offline',
     '/dom/src/storage',
     '/dom/telephony',
     '/dom/xbl',
     '/dom/xslt/base',
     '/dom/xslt/xml',
     '/dom/xslt/xpath',
--- a/testing/xpcshell/xpcshell_android.ini
+++ b/testing/xpcshell/xpcshell_android.ini
@@ -6,23 +6,23 @@
 [include:chrome/test/unit/xpcshell.ini]
 [include:content/base/test/unit/xpcshell.ini]
 [include:content/test/unit/xpcshell.ini]
 [include:docshell/test/unit/xpcshell.ini]
 [include:dom/activities/tests/unit/xpcshell.ini]
 [include:dom/apps/tests/unit/xpcshell.ini]
 [include:dom/encoding/test/unit/xpcshell.ini]
 [include:dom/indexedDB/test/unit/xpcshell.ini]
+[include:dom/json/test/unit/xpcshell.ini]
 [include:dom/mobilemessage/tests/xpcshell/xpcshell.ini]
 [include:dom/network/tests/unit/xpcshell.ini]
 [include:dom/network/tests/unit_stats/xpcshell.ini]
 [include:dom/payment/tests/unit/xpcshell.ini]
 [include:dom/permission/tests/unit/xpcshell.ini]
 [include:dom/resourcestats/tests/xpcshell/xpcshell.ini]
-[include:dom/src/json/test/unit/xpcshell.ini]
 [include:dom/tests/unit/xpcshell.ini]
 [include:embedding/tests/unit/xpcshell.ini]
 [include:gfx/tests/unit/xpcshell.ini]
 [include:image/test/unit/xpcshell.ini]
 [include:intl/locale/tests/unit/xpcshell.ini]
 [include:intl/strres/tests/unit/xpcshell.ini]
 [include:intl/uconv/tests/unit/xpcshell.ini]
 [include:intl/unicharutil/tests/unit/xpcshell.ini]