Sha256: 2c5062c860efb18ff1a88648426f0f8913905a92983abba96c94975f306efe37
Contents?: true
Size: 559 Bytes
Versions: 11
Compression:
Stored size: 559 Bytes
Contents
u = up.util e = up.element $ = jQuery beforeEach -> jasmine.addMatchers toHaveOpacity: (util, customEqualityTesters) -> compare: (element, expectedOpacity, tolerance = 0.0) -> element = e.get(element) actualOpacity = e.styleNumber(element, 'opacity') result = {} result.pass = Math.abs(expectedOpacity - actualOpacity) <= tolerance unless result.pass result.message = up.log.sprintf("Expected %o to have opacity %o, but it was %o", element, expectedOpacity, actualOpacity) return result
Version data entries
11 entries across 11 versions & 1 rubygems