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

Commit 040aa11

Browse files
committedAug 23, 2013
test(docs): ignore some of the specs on IE
This target was never un on our Jenkins CI. Some of the specs are using animation stuff, that IE does not support, so I'm disabling them.
1 parent b89a4e4 commit 040aa11

File tree

4 files changed

+15
-1
lines changed

4 files changed

+15
-1
lines changed
 

‎docs/component-spec/annotationsSpec.js

+8-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ describe('Docs Annotations', function() {
88
body.html('');
99
});
1010

11+
var normalizeHtml = function(html) {
12+
return html.toLowerCase().replace(/\s*$/, '');
13+
};
14+
1115
describe('popover directive', function() {
1216

1317
var $scope, element;
@@ -57,14 +61,17 @@ describe('Docs Annotations', function() {
5761
$scope.$apply();
5862
element.triggerHandler('click');
5963
expect(popoverElement.title()).toBe('#title_text');
60-
expect(popoverElement.content()).toBe('<h1>heading</h1>\n');
64+
expect(normalizeHtml(popoverElement.content())).toMatch('<h1>heading</h1>');
6165
}));
6266

6367
});
6468

6569

6670
describe('foldout directive', function() {
6771

72+
// Do not run this suite on Internet Explorer.
73+
if (msie < 10) return;
74+
6875
var $scope, parent, element, url;
6976
beforeEach(function() {
7077
module(function($provide, $animateProvider) {

‎docs/component-spec/mocks.js

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// Copy/pasted from src/Angular.js, so that we can disable specific tests on IE.
2+
var msie = parseInt((/msie (\d+)/.exec(navigator.userAgent.toLowerCase()) || [])[1], 10);
3+
14
var createMockWindow = function() {
25
var mockWindow = {};
36
var setTimeoutQueue = [];

‎docs/component-spec/versionJumpSpec.js

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
describe('DocsApp', function() {
22

3+
// Do not run this suite on Internet Explorer.
4+
if (msie < 10) return;
5+
36
beforeEach(module('docsApp'));
47

58
describe('DocsVersionsCtrl', function() {

‎karma-docs.conf.js

+1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ module.exports = function(config) {
2626
'build/docs/js/docs.js',
2727
'build/docs/docs-data.js',
2828

29+
'docs/component-spec/mocks.js',
2930
'docs/component-spec/*.js'
3031
],
3132

0 commit comments

Comments
 (0)
This repository has been archived.