Created
November 12, 2010 16:52
-
-
Save joecorcoran/674339 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
toHaveEvent: function(eventType){ | |
return (this.actual.data('events')) && (typeof this.actual.data('events')[eventType] == 'object'); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
toHaveLive: function(eventType) { | |
var hasLive, actual = this.actual; | |
$.each($(document).data('events')['live'], function(i, item) { | |
hasLive = ((item.selector == actual.selector) && (item.origType == eventType)); | |
if (hasLive) return false; | |
}); | |
return hasLive; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment