OLD | NEW |
1 suite('apply-preserving-inline-style', function() { | 1 suite('apply-preserving-inline-style', function() { |
2 setup(function() { | 2 setup(function() { |
3 this.element = document.createElement('div'); | 3 this.element = document.createElement('div'); |
4 ensureStyleIsPatched(this.element); | 4 ensureStyleIsPatched(this.element); |
5 this.style = this.element.style; | 5 this.style = this.element.style; |
6 document.documentElement.appendChild(this.element); | 6 document.documentElement.appendChild(this.element); |
7 }); | 7 }); |
8 teardown(function() { | 8 teardown(function() { |
9 this.element.remove(); | 9 this.element.remove(); |
10 }); | 10 }); |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 test('Patched cssText', function() { | 63 test('Patched cssText', function() { |
64 this.style._set('left', '100px'); | 64 this.style._set('left', '100px'); |
65 assert.equal(this.style.length, 0); | 65 assert.equal(this.style.length, 0); |
66 this.style.setProperty('left', '0px'); | 66 this.style.setProperty('left', '0px'); |
67 this.style.setProperty('background-color', 'rgb(1, 2, 3)'); | 67 this.style.setProperty('background-color', 'rgb(1, 2, 3)'); |
68 assert.equal(this.style.length, 2); | 68 assert.equal(this.style.length, 2); |
69 this.style.cssText = 'top: 0px'; | 69 this.style.cssText = 'top: 0px'; |
70 assert.equal(this.style.length, 1); | 70 assert.equal(this.style.length, 1); |
71 }); | 71 }); |
72 }); | 72 }); |
OLD | NEW |