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

Commit a18eed9

Browse files
committed
test(IE8) Remove special code for IE8
1 parent 4df2311 commit a18eed9

File tree

4 files changed

+2
-15
lines changed

4 files changed

+2
-15
lines changed

test/ng/compileSpec.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1356,7 +1356,7 @@ describe('$compile', function() {
13561356

13571357
$rootScope.$digest();
13581358

1359-
expect(sortedHtml(element)).toBe('<div><span class="i-hello">Hello, Elvis!</span></div>');
1359+
expect(sortedHtml(element)).toEqual('<div><span class="i-hello">Hello, Elvis!</span></div>');
13601360
}
13611361
));
13621362

test/ng/httpBackendSpec.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ describe('$httpBackend', function() {
235235

236236

237237
it('should read responseText if response was not defined', function() {
238-
// old browsers like IE8, don't support responseType, so they always respond with responseText
238+
// old browsers like IE9, don't support responseType, so they always respond with responseText
239239

240240
$backend('GET', '/whatever', null, callback, {}, null, null, 'blob');
241241

test/ng/sceSpecs.js

-6
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,6 @@
22

33
describe('SCE', function() {
44

5-
// Work around an IE8 bug. Though window.inject === angular.mock.inject, if it's invoked the
6-
// window scope, IE8 loses the exception object that bubbles up and replaces it with a TypeError.
7-
// By using a local alias, it gets invoked on the global scope instead of window.
8-
// Ref: https://github.com/angular/angular.js/pull/4221#/issuecomment-25515813
9-
var inject = angular.mock.inject;
10-
115
describe('when disabled', function() {
126
beforeEach(function() {
137
module(function($sceProvider) {

test/ngMock/angular-mocksSpec.js

-7
Original file line numberDiff line numberDiff line change
@@ -719,8 +719,6 @@ describe('ngMock', function() {
719719

720720
it('should serialize scope that has overridden "hasOwnProperty"', inject(function($rootScope, $sniffer) {
721721
/* jshint -W001 */
722-
// MS IE8 just doesn't work for this kind of thing, since "for ... in" doesn't return
723-
// things like hasOwnProperty even if it is explicitly defined on the actual object!
724722
$rootScope.hasOwnProperty = 'X';
725723
expect(d($rootScope)).toMatch(/Scope\(.*\): \{/);
726724
expect(d($rootScope)).toMatch(/hasOwnProperty: "X"/);
@@ -905,11 +903,6 @@ describe('ngMock', function() {
905903
});
906904
});
907905

908-
909-
// We don't run the following tests on IE8.
910-
// IE8 throws "Object does not support this property or method." error,
911-
// when thrown from a function defined on window (which `inject` is).
912-
913906
it('should not change thrown Errors', inject(function($sniffer) {
914907
expect(function() {
915908
inject(function() {

0 commit comments

Comments
 (0)