 
       changeInputValue = (element, value) ->
         element.val value
-        element.trigger (if $sniffer.hasEvent("input") then "input" else "change")
+        element.triggerHandler (if $sniffer.hasEvent("input") then "input" else "change")
 
     it "should update the model correctly", ->
       $rootScope.model = ""
       element          = $compile("<mac-time ng-model='model'></mac-time>") $rootScope
       $rootScope.$digest()
 
-      element.click()
+      element.triggerHandler 'click'
       changeInputValue element, "06:25 PM"
 
       expect($rootScope.model).toBe "06:25 PM"

      element          = $compile("<mac-time ng-model='model'></mac-time>") $rootScope
      $rootScope.$digest()

      element.click()
      $rootScope.$digest()

      changeInputValue element, "123"
      element.trigger 'blur'
      $rootScope.$digest()

      expect($rootScope.model).toBe("12:00 AM")

      element          = $compile("<mac-time ng-model='model'></mac-time>") $rootScope
      $rootScope.$digest()

      element.triggerHandler 'click'
      $rootScope.$digest()

      changeInputValue element, "14:41 AM"
      element.triggerHandler 'blur'
      $rootScope.$digest()

      expect($rootScope.model).toBe("12:00 AM")
