       modalElement      = $compile("<mac-modal id='test-modal' mac-modal-open='opened()'></mac-modal>") $rootScope
       $rootScope.$digest()
 
+      expect(opened).toBe false
       modal.show "test-modal"
       $timeout.flush()
 

      modalElement          = $compile("<mac-modal id='test-modal' mac-modal-before-hide='beforeHide()'></mac-modal>") $rootScope
      $rootScope.$digest()

      modal.show "test-modal"
      $timeout.flush()
      modal.hide()


      modalElement          = $compile("<mac-modal id='test-modal' mac-modal-before-show='beforeShow()'></mac-modal>") $rootScope
      $rootScope.$digest()

      expect($rootScope.beforeShow).not.toHaveBeenCalled()

      modal.show "test-modal"
      $timeout.flush()

