diffux_ci 0.4.4 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/diffux_ci/public/diffux_ci-runner.js +16 -3
- data/lib/diffux_ci/version.rb +1 -1
- metadata +1 -2
- data/lib/public/diffux_ci-scripts.js +0 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d71ccdac8e66bd426e7ddb84f4d09423780606d7
|
4
|
+
data.tar.gz: 0adf694bcf203f34bb8dc87b08e79c596c68d80f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 778314460045c284beeb1eab8446e58c8f95d5619220c2d2c6887ff121b095cb73bbfbd7891055c32c3dc5ff4e2454551447119c2b2aeacfa3c164d81b0d89d0
|
7
|
+
data.tar.gz: 4f242e480d4a70d4aa098b2a1ea29ec0bc8cf32128b952c48e419ec7f8b1e77092b38a50a57e9df23358ca5e92c402cad3afa0c158f46d4e2d48cad00577b041
|
@@ -44,7 +44,7 @@ window.diffux = {
|
|
44
44
|
},
|
45
45
|
|
46
46
|
handleError: function(currentExample, error) {
|
47
|
-
console.error(error);
|
47
|
+
console.error(error.stack);
|
48
48
|
return {
|
49
49
|
description: currentExample.description,
|
50
50
|
error: error.message
|
@@ -132,8 +132,21 @@ window.diffux = {
|
|
132
132
|
} else {
|
133
133
|
// The function does not take an argument, so we can run it
|
134
134
|
// synchronously.
|
135
|
-
var
|
136
|
-
|
135
|
+
var result = func();
|
136
|
+
|
137
|
+
if (result instanceof Promise) {
|
138
|
+
// The function returned a promise, so we need to wait for it to
|
139
|
+
// resolve before proceeding.
|
140
|
+
result.then(function(elem) {
|
141
|
+
doneFunc(this.processElem(currentExample, elem));
|
142
|
+
}.bind(this)).catch(function(error) {
|
143
|
+
doneFunc(this.handleError(currentExample, error));
|
144
|
+
}.bind(this));
|
145
|
+
} else {
|
146
|
+
// The function did not return a promise, so we assume it gave us an
|
147
|
+
// element that we can process immediately.
|
148
|
+
doneFunc(this.processElem(currentExample, result));
|
149
|
+
}
|
137
150
|
}
|
138
151
|
} catch (error) {
|
139
152
|
doneFunc(this.handleError(currentExample, error));
|
data/lib/diffux_ci/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: diffux_ci
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Henric Trotzig
|
@@ -149,7 +149,6 @@ files:
|
|
149
149
|
- lib/diffux_ci/views/debug.erb
|
150
150
|
- lib/diffux_ci/views/index.erb
|
151
151
|
- lib/diffux_ci/views/review.erb
|
152
|
-
- lib/public/diffux_ci-scripts.js
|
153
152
|
homepage: http://rubygems.org/gems/diffux_ci
|
154
153
|
licenses:
|
155
154
|
- MIT
|