Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 71908a0

Browse files
committed
fixup test exclusions for Edge 14
1 parent 8623015 commit 71908a0

File tree

2 files changed

+38
-38
lines changed

2 files changed

+38
-38
lines changed

test/ng/animateRunnerSpec.js

+30-32
Original file line numberDiff line numberDiff line change
@@ -329,45 +329,43 @@ describe('$$AnimateRunner', function() {
329329
expect(status).toBe(true);
330330
}));
331331

332-
if (!edge) {
333-
it('should break the chain when a function evaluates to false',
334-
inject(function($$rAF, $$AnimateRunner) {
332+
it('should break the chain when a function evaluates to false',
333+
inject(function($$rAF, $$AnimateRunner) {
335334

336-
var runner1 = new $$AnimateRunner();
337-
var runner2 = new $$AnimateRunner();
338-
var runner3 = new $$AnimateRunner();
339-
var runner4 = new $$AnimateRunner();
340-
var runner5 = new $$AnimateRunner();
341-
var runner6 = new $$AnimateRunner();
335+
var runner1 = new $$AnimateRunner();
336+
var runner2 = new $$AnimateRunner();
337+
var runner3 = new $$AnimateRunner();
338+
var runner4 = new $$AnimateRunner();
339+
var runner5 = new $$AnimateRunner();
340+
var runner6 = new $$AnimateRunner();
342341

343-
var log = [];
342+
var log = [];
344343

345-
var items = [];
346-
items.push(function(fn) { log.push(1); runner1.done(fn); });
347-
items.push(function(fn) { log.push(2); runner2.done(fn); });
348-
items.push(function(fn) { log.push(3); runner3.done(fn); });
349-
items.push(function(fn) { log.push(4); runner4.done(fn); });
350-
items.push(function(fn) { log.push(5); runner5.done(fn); });
351-
items.push(function(fn) { log.push(6); runner6.done(fn); });
344+
var items = [];
345+
items.push(function(fn) { log.push(1); runner1.done(fn); });
346+
items.push(function(fn) { log.push(2); runner2.done(fn); });
347+
items.push(function(fn) { log.push(3); runner3.done(fn); });
348+
items.push(function(fn) { log.push(4); runner4.done(fn); });
349+
items.push(function(fn) { log.push(5); runner5.done(fn); });
350+
items.push(function(fn) { log.push(6); runner6.done(fn); });
352351

353-
var status;
354-
$$AnimateRunner.chain(items, function(response) {
355-
status = response;
356-
});
352+
var status;
353+
$$AnimateRunner.chain(items, function(response) {
354+
status = response;
355+
});
357356

358-
runner1.complete('');
359-
runner2.complete(null);
360-
runner3.complete(undefined);
361-
runner4.complete(0);
362-
runner5.complete(false);
357+
runner1.complete('');
358+
runner2.complete(null);
359+
runner3.complete(undefined);
360+
runner4.complete(0);
361+
runner5.complete(false);
363362

364-
runner6.complete(true);
363+
runner6.complete(true);
365364

366-
$$rAF.flush();
365+
$$rAF.flush();
367366

368-
expect(log).toEqual([1,2,3,4,5]);
369-
expect(status).toBe(false);
370-
}));
371-
}
367+
expect(log).toEqual([1,2,3,4,5]);
368+
expect(status).toBe(false);
369+
}));
372370
});
373371
});

test/ng/directive/inputSpec.js

+8-6
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
describe('input', function() {
66
var helper = {}, $compile, $rootScope, $browser, $sniffer, $timeout, $q;
77

8+
// UA sniffing to exclude Edge from some date input tests
9+
var isEdge = /\bEdge\/[\d\.]+\b/.test(window.navigator.userAgent);
10+
811
generateInputCompilerHelper(helper);
912

1013
beforeEach(inject(function(_$compile_, _$rootScope_, _$browser_, _$sniffer_, _$timeout_, _$q_) {
@@ -689,8 +692,8 @@ describe('input', function() {
689692
});
690693

691694

692-
if (!edge) {
693-
it('should allow four or more digits in year', function() {
695+
if (!isEdge) {
696+
fit('should allow four or more digits in year', function() {
694697
var inputElm = helper.compileInput('<input type="month" ng-model="value" ng-model-options="{timezone: \'UTC\'}"/>');
695698

696699
helper.changeInputValueTo('10123-03');
@@ -703,7 +706,6 @@ describe('input', function() {
703706
});
704707
}
705708

706-
707709
it('should only change the month of a bound date', function() {
708710
var inputElm = helper.compileInput('<input type="month" ng-model="value" ng-model-options="{timezone: \'UTC\'}" />');
709711

@@ -902,7 +904,7 @@ describe('input', function() {
902904
expect(inputElm).toBeValid();
903905
});
904906

905-
if (!edge) {
907+
if (!isEdge) {
906908
it('should allow four or more digits in year', function() {
907909
var inputElm = helper.compileInput('<input type="week" ng-model="value" ng-model-options="{timezone: \'UTC\'}"/>');
908910

@@ -1201,7 +1203,7 @@ describe('input', function() {
12011203
});
12021204

12031205

1204-
if (!edge) {
1206+
if (!isEdge) {
12051207
it('should allow four or more digits in year', function() {
12061208
var inputElm = helper.compileInput('<input type="datetime-local" ng-model="value" />');
12071209

@@ -1809,7 +1811,7 @@ describe('input', function() {
18091811
}
18101812
);
18111813

1812-
if (!edge) {
1814+
if (!isEdge) {
18131815
it('should allow four or more digits in year', function() {
18141816
var inputElm = helper.compileInput('<input type="date" ng-model="value" ng-model-options="{timezone: \'UTC\'}" />');
18151817

0 commit comments

Comments
 (0)