1
0
Переглянути джерело

libs: amber_core => amber/core in deps

+ forgotten previous transformations for tests
Herby Vojčík 5 роки тому
батько
коміт
670de53d7a
5 змінених файлів з 15 додано та 21 видалено
  1. 5 5
      Gruntfile.js
  2. 1 1
      package.json
  3. 7 13
      src/Silk-Tests.js
  4. 1 1
      src/Silk.js
  5. 1 1
      testing.js

+ 5 - 5
Gruntfile.js

@@ -59,7 +59,7 @@ module.exports = function (grunt) {
                     'src/Silk-Tests.st' // list all tests in dependency order
                 ],
                 amd_namespace: 'silk',
-                libraries: ['amber_core/SUnit', 'amber/domite/DOMite', 'amber/domite/DOMite-Tests']
+                libraries: ['amber/core/SUnit', 'amber/domite/DOMite', 'amber/domite/DOMite-Tests']
             }
         },
 
@@ -74,7 +74,7 @@ module.exports = function (grunt) {
                     mainConfigFile: "config.js",
                     rawText: {
                         "app": '(' + polyfillThenPromiseApp + '());',
-                        "__app__": 'define(["deploy", "amber_core/Platform-Browser"],function(x){return x});'
+                        "__app__": 'define(["deploy", "amber/core/Platform-Browser"],function(x){return x});'
                     },
                     pragmas: {
                         excludeIdeData: true,
@@ -91,10 +91,10 @@ module.exports = function (grunt) {
                     mainConfigFile: "config.js",
                     rawText: {
                         "app": '(' + polyfillThenPromiseApp + '());',
-                        "__app__": 'define(["devel", "amber_core/Platform-Browser"],function(x){return x});'
+                        "__app__": 'define(["devel", "amber/core/Platform-Browser"],function(x){return x});'
                     },
                     include: ['config', 'node_modules/requirejs/require', 'app', '__app__'],
-                    exclude: ['devel', 'amber_core/Platform-Browser'],
+                    exclude: ['devel', 'amber/core/Platform-Browser'],
                     out: "the.js"
                 }
             },
@@ -104,7 +104,7 @@ module.exports = function (grunt) {
                     rawText: {
                         "jquery": "/* do not load in node test runner */",
                         "__app__": "(" + function () {
-                            define(["testing", "amber_core/Platform-Node", "amber_devkit/NodeTestRunner"], function (amber) {
+                            define(["testing", "amber/core/Platform-Node", "amber_devkit/NodeTestRunner"], function (amber) {
                                 amber.initialize().then(function () {
                                     amber.globals.NodeTestRunner._main();
                                 });

+ 1 - 1
package.json

@@ -31,7 +31,7 @@
     "test": "grunt test"
   },
   "dependencies": {
-    "@ambers/lang": ">=0.22.2",
+    "@ambers/lang": ">0.22.6",
     "@ambers/domite": "^0.8.0"
   },
   "devDependencies": {

+ 7 - 13
src/Silk-Tests.js

@@ -1,18 +1,12 @@
-define(["amber/boot"
+define(["amber/boot", "require", "amber/core/SUnit", "domite/DOMite-Tests"], function($boot,requirejs){"use strict";
+var $core=$boot.api,nil=$boot.nilAsValue,$nil=$boot.nilAsReceiver,$recv=$boot.asReceiver,$globals=$boot.globals;
+var $pkg = $core.addPackage("Silk-Tests");
+$pkg.innerEval = function (expr) { return eval(expr); };
+$pkg.imports = ["amber/jquery/Wrappers-JQuery"];
 //>>excludeStart("imports", pragmas.excludeImports);
-, "amber/jquery/Wrappers-JQuery"
+$pkg.isReady = new Promise(function (resolve, reject) { requirejs(["amber/jquery/Wrappers-JQuery"], function () {resolve();}, reject); });
 //>>excludeEnd("imports");
-, "amber_core/SUnit", "domite/DOMite-Tests"], function($boot
-//>>excludeStart("imports", pragmas.excludeImports);
-
-//>>excludeEnd("imports");
-){"use strict";
-if(!("nilAsValue" in $boot))$boot.nilAsValue=$boot.nilAsReceiver;
-var $core=$boot.api,nil=$boot.nilAsValue,$nil=$boot.nilAsReceiver,$recv=$boot.asReceiver,$globals=$boot.globals;
-$core.addPackage("Silk-Tests");
-($core.packageDescriptors||$core.packages)["Silk-Tests"].innerEval = function (expr) { return eval(expr); };
-($core.packageDescriptors||$core.packages)["Silk-Tests"].imports = ["amber/jquery/Wrappers-JQuery"];
-($core.packageDescriptors||$core.packages)["Silk-Tests"].transport = {"type":"amd","amdNamespace":"silk"};
+$pkg.transport = {"type":"amd","amdNamespace":"silk"};
 
 $core.addClass("SilkInheritedTest", $globals.DOMiteTest, [], "Silk-Tests");
 $core.addMethod(

+ 1 - 1
src/Silk.js

@@ -1,4 +1,4 @@
-define(["amber/boot", "require", "amber_core/Kernel-Collections", "amber_core/Kernel-Infrastructure", "amber_core/Kernel-Methods", "amber_core/Kernel-Objects", "domite/DOMite"], function($boot,requirejs){"use strict";
+define(["amber/boot", "require", "amber/core/Kernel-Collections", "amber/core/Kernel-Infrastructure", "amber/core/Kernel-Methods", "amber/core/Kernel-Objects", "domite/DOMite"], function($boot,requirejs){"use strict";
 var $core=$boot.api,nil=$boot.nilAsValue,$nil=$boot.nilAsReceiver,$recv=$boot.asReceiver,$globals=$boot.globals;
 var $pkg = $core.addPackage("Silk");
 $pkg.innerEval = function (expr) { return eval(expr); };

+ 1 - 1
testing.js

@@ -1,6 +1,6 @@
 define([
     './deploy',
-    'amber_core/SUnit',
+    'amber/core/SUnit',
     // --- packages used only during automated testing begin here ---
     'silk/Silk-Tests'
     // --- packages used only during automated testing end here ---