You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by GitBox <gi...@apache.org> on 2018/11/30 14:27:08 UTC

[GitHub] brodybits closed pull request #73: More verbose test reporter

brodybits closed pull request #73: More verbose test reporter
URL: https://github.com/apache/cordova-osx/pull/73
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/package-lock.json b/package-lock.json
index 28141dfd..a0312ce4 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -374,6 +374,11 @@
       "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
       "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU="
     },
+    "colors": {
+      "version": "1.1.2",
+      "resolved": "http://registry.npmjs.org/colors/-/colors-1.1.2.tgz",
+      "integrity": "sha1-FopHAXVran9RoSzgyXv6KMCE7WM="
+    },
     "concat-map": {
       "version": "0.0.1",
       "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
@@ -1186,6 +1191,14 @@
       "integrity": "sha512-3/xSmG/d35hf80BEN66Y6g9Ca5l/Isdeg/j6zvbTYlTzeKinzmaTM4p9am5kYqOmE05D7s1t8FGjzdSnbUbceA==",
       "dev": true
     },
+    "jasmine-spec-reporter": {
+      "version": "4.2.1",
+      "resolved": "https://registry.npmjs.org/jasmine-spec-reporter/-/jasmine-spec-reporter-4.2.1.tgz",
+      "integrity": "sha512-FZBoZu7VE5nR7Nilzy+Np8KuVIOxF4oXDPDknehCYBDE080EnlPu0afdZNmpGDBRCUBv3mj5qgqCRmk6W/K8vg==",
+      "requires": {
+        "colors": "1.1.2"
+      }
+    },
     "js-tokens": {
       "version": "3.0.2",
       "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz",
diff --git a/package.json b/package.json
index 361247b9..27c3fad2 100644
--- a/package.json
+++ b/package.json
@@ -26,6 +26,7 @@
   "license": "Apache-2.0",
   "dependencies": {
     "cordova-common": "^3.0.0",
+    "jasmine-spec-reporter": "^4.2.1",
     "nopt": "^3.0.6",
     "q": "^1.4.1",
     "shelljs": "^0.5.3",
diff --git a/tests/spec/component.json b/tests/spec/component.json
index d8a708ab..81b9feeb 100644
--- a/tests/spec/component.json
+++ b/tests/spec/component.json
@@ -3,6 +3,9 @@
   "spec_files": [
       "component/**/*[sS]pec.js"
   ],
+  "helpers": [
+      "helper.js"
+  ],
   "stopSpecOnExpectationFailure": false,
   "random": false
 }
diff --git a/tests/spec/coverage.json b/tests/spec/coverage.json
index 10bcef3a..d2e78c4c 100644
--- a/tests/spec/coverage.json
+++ b/tests/spec/coverage.json
@@ -4,6 +4,9 @@
       "component/**/*[sS]pec.js",
       "objc/**/*[sS]pec.js"
   ],
+  "helpers": [
+      "helper.js"
+  ],
   "stopSpecOnExpectationFailure": false,
   "random": false
 }
diff --git a/tests/spec/helper.js b/tests/spec/helper.js
new file mode 100644
index 00000000..a4a58865
--- /dev/null
+++ b/tests/spec/helper.js
@@ -0,0 +1,31 @@
+/**
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+*/
+const SpecReporter = require('jasmine-spec-reporter').SpecReporter;
+
+jasmine.getEnv().clearReporters();
+jasmine.getEnv().addReporter(new SpecReporter({
+    spec: {
+        displayPending: true,
+        displayDuration: true
+    },
+    summary: {
+        displayDuration: true,
+        displayStacktrace: true
+    }
+}));
diff --git a/tests/spec/objc.json b/tests/spec/objc.json
index bad2444a..5fe76bd2 100644
--- a/tests/spec/objc.json
+++ b/tests/spec/objc.json
@@ -3,6 +3,9 @@
   "spec_files": [
       "objc/**/*[sS]pec.js"
   ],
+  "helpers": [
+      "helper.js"
+  ],
   "stopSpecOnExpectationFailure": false,
   "random": false
 }


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org