Skip to content

Commit 955ec16

Browse files
committed
jqLiteExtras .height() tests update due to changes in jQuery 3
1 parent 6c023f3 commit 955ec16

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

test/jqliteExtrasSpec.js

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -89,16 +89,12 @@ describe('\njqLite: testing against jQuery\n', function () {
8989
'<div style="padding: 3em">some text w padding</div>',
9090
'<div style="margin: 3px">some text w margin</div>',
9191
'<div style="margin: 3em">some text w margin</div>',
92-
'<div style="margin: 3pt">some text w margin</div>',
93-
'<div style="line-height: 1.1em">some text w line height</div>'
92+
'<div style="margin: 3pt">some text w margin</div>'
9493
], function(element) {
9594

96-
/*function validateHeight(element) {
97-
expect(extras.prototype.height.call(element)).toBe(element.height());
98-
var h = element.height();
99-
extras.prototype.height.call(element, h*2);
100-
expect(extras.prototype.height.call(element)).toBe(h*2);
101-
}*/
95+
// Since jQuery v3 the .hegth() results don't being rounded (https://github.com/jquery/jquery/pull/2454).
96+
// So the element '<div style="line-height: 1.1em">some text w line height</div>' will cause the error --
97+
// Expected 18 to be 17.6
10298

10399
it('height(value) for ' + element, function() {
104100
(function (element) {

0 commit comments

Comments
 (0)