jasmine-core 2.3.3 → 2.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 62b63c2afe6af61a81fe7a0325115f52005da3cf
4
- data.tar.gz: 084d5b07313cae31f03f76e48df8c33c5318b8bd
3
+ metadata.gz: 6669e6ffbda26ae89717b96dd916f40d380d5bda
4
+ data.tar.gz: a0a3fa81cdc125d9212f5ddf2a6816ba92cd556c
5
5
  SHA512:
6
- metadata.gz: ee03760e7c755b1ba5c34ea64bbe7242d6b0556f0dc341af2495ffb6bac0f0abe31f049bb30476dff678fd817c77835faa04b565dd25930a3895237de2fb78f6
7
- data.tar.gz: d0b7bf5e4eb688fce121bfe4dcfe768702048668f323b6cfda045ac1457c43172344680a687128891d41ebb196715472e467e017d8c7e3a1985b3c8f0506cd30
6
+ metadata.gz: 5d5acc2b403f7882cab16aab3d1d022ff1a35a53b2e357e69e25b6a93461cccdcb91289f945ebd12ea298a3029bd7089a12e3b21cc40de49a173de2743d20227
7
+ data.tar.gz: cf5c9b6def40a3fb5c1b0f3368932f6d81e3b546d9ac8f180d96e82d48c271d6e56bc1bed30934a6745cae9006e2c1bb217000fb191fd40fd101f3a1c7cad6f6
@@ -38,14 +38,7 @@ body { overflow-y: scroll; }
38
38
  .jasmine_html-reporter .bar a { color: white; }
39
39
  .jasmine_html-reporter.spec-list .bar.menu.failure-list, .jasmine_html-reporter.spec-list .results .failures { display: none; }
40
40
  .jasmine_html-reporter.failure-list .bar.menu.spec-list, .jasmine_html-reporter.failure-list .summary { display: none; }
41
- .jasmine_html-reporter .running-alert { background-color: #666; }
42
41
  .jasmine_html-reporter .results { margin-top: 14px; }
43
- .jasmine_html-reporter.showDetails .summaryMenuItem { font-weight: normal; text-decoration: inherit; }
44
- .jasmine_html-reporter.showDetails .summaryMenuItem:hover { text-decoration: underline; }
45
- .jasmine_html-reporter.showDetails .detailsMenuItem { font-weight: bold; text-decoration: underline; }
46
- .jasmine_html-reporter.showDetails .summary { display: none; }
47
- .jasmine_html-reporter.showDetails #details { display: block; }
48
- .jasmine_html-reporter .summaryMenuItem { font-weight: bold; text-decoration: underline; }
49
42
  .jasmine_html-reporter .summary { margin-top: 14px; }
50
43
  .jasmine_html-reporter .summary ul { list-style-type: none; margin-left: 14px; padding-top: 0; padding-left: 0; }
51
44
  .jasmine_html-reporter .summary ul.suite { margin-top: 7px; margin-bottom: 7px; }
@@ -2311,30 +2311,29 @@ getJasmineRequireObj().TreeProcessor = function() {
2311
2311
  }
2312
2312
 
2313
2313
  function orderChildSegments(children) {
2314
- var result = [];
2314
+ var specifiedOrder = [],
2315
+ unspecifiedOrder = [];
2315
2316
 
2316
2317
  for (var i = 0; i < children.length; i++) {
2317
2318
  var child = children[i],
2318
2319
  segments = stats[child.id].segments;
2319
2320
 
2320
2321
  for (var j = 0; j < segments.length; j++) {
2321
- result.push(segments[j]);
2322
- }
2323
- }
2324
-
2325
- result.sort(function(a, b) {
2326
- if (a.min === null) {
2327
- return b.min === null ? 0 : 1;
2328
- }
2322
+ var seg = segments[j];
2329
2323
 
2330
- if (b.min === null) {
2331
- return -1;
2324
+ if (seg.min === defaultMin) {
2325
+ unspecifiedOrder.push(seg);
2326
+ } else {
2327
+ specifiedOrder.push(seg);
2328
+ }
2332
2329
  }
2330
+ }
2333
2331
 
2332
+ specifiedOrder.sort(function(a, b) {
2334
2333
  return a.min - b.min;
2335
2334
  });
2336
2335
 
2337
- return result;
2336
+ return specifiedOrder.concat(unspecifiedOrder);
2338
2337
  }
2339
2338
 
2340
2339
  function executeNode(node, segmentNumber) {
@@ -3295,5 +3294,5 @@ getJasmineRequireObj().interface = function(jasmine, env) {
3295
3294
  };
3296
3295
 
3297
3296
  getJasmineRequireObj().version = function() {
3298
- return '2.3.3';
3297
+ return '2.3.4';
3299
3298
  };
@@ -632,4 +632,62 @@ describe("TreeProcessor", function() {
632
632
  childFns[1].fn();
633
633
  expect(leaf3.execute).toHaveBeenCalled();
634
634
  });
635
+
636
+ it("runs large segments of nodes in the order they were declared", function() {
637
+ var leaf1 = new Leaf(),
638
+ leaf2 = new Leaf(),
639
+ leaf3 = new Leaf(),
640
+ leaf4 = new Leaf(),
641
+ leaf5 = new Leaf(),
642
+ leaf6 = new Leaf(),
643
+ leaf7 = new Leaf(),
644
+ leaf8 = new Leaf(),
645
+ leaf9 = new Leaf(),
646
+ leaf10 = new Leaf(),
647
+ leaf11 = new Leaf(),
648
+ root = new Node({ children: [leaf1, leaf2, leaf3, leaf4, leaf5, leaf6, leaf7, leaf8, leaf9, leaf10, leaf11] }),
649
+ queueRunner = jasmine.createSpy('queueRunner'),
650
+ processor = new j$.TreeProcessor({
651
+ tree: root,
652
+ runnableIds: [root.id],
653
+ queueRunnerFactory: queueRunner
654
+ });
655
+
656
+ processor.execute();
657
+ var queueableFns = queueRunner.calls.mostRecent().args[0].queueableFns;
658
+ expect(queueableFns.length).toBe(11);
659
+
660
+ queueableFns[0].fn();
661
+ expect(leaf1.execute).toHaveBeenCalled();
662
+
663
+ queueableFns[1].fn();
664
+ expect(leaf2.execute).toHaveBeenCalled();
665
+
666
+ queueableFns[2].fn();
667
+ expect(leaf3.execute).toHaveBeenCalled();
668
+
669
+ queueableFns[3].fn();
670
+ expect(leaf4.execute).toHaveBeenCalled();
671
+
672
+ queueableFns[4].fn();
673
+ expect(leaf5.execute).toHaveBeenCalled();
674
+
675
+ queueableFns[5].fn();
676
+ expect(leaf6.execute).toHaveBeenCalled();
677
+
678
+ queueableFns[6].fn();
679
+ expect(leaf7.execute).toHaveBeenCalled();
680
+
681
+ queueableFns[7].fn();
682
+ expect(leaf8.execute).toHaveBeenCalled();
683
+
684
+ queueableFns[8].fn();
685
+ expect(leaf9.execute).toHaveBeenCalled();
686
+
687
+ queueableFns[9].fn();
688
+ expect(leaf10.execute).toHaveBeenCalled();
689
+
690
+ queueableFns[10].fn();
691
+ expect(leaf11.execute).toHaveBeenCalled();
692
+ });
635
693
  });
@@ -4,6 +4,6 @@
4
4
  #
5
5
  module Jasmine
6
6
  module Core
7
- VERSION = "2.3.3"
7
+ VERSION = "2.3.4"
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jasmine-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.3
4
+ version: 2.3.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rajan Agaskar
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2015-05-11 00:00:00.000000000 Z
13
+ date: 2015-05-13 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rake