Flowdock
method

test_unadvise

Importance_0
v1_8_7_330 - Show latest stable - 0 notes - Class: TestWIN32OLE_EVENT
test_unadvise() public

No documentation

This method has no description. You can help the Ruby community by adding new notes.

Hide source
# File ext/win32ole/tests/test_win32ole_event.rb, line 94
    def test_unadvise
      ev = WIN32OLE_EVENT.new(@ie, 'DWebBrowserEvents')
      ev.on_event {|*args| default_handler(*args)}
      @ie.navigate("file:///#{@f}")
      while @ie.busy
        sleep 0.1
      end
      assert_match(/BeforeNavigate/, @event)
      ev.unadvise
      @event = ""
      @ie.navigate("file:///#{@f}")
      while @ie.busy
        sleep 0.1
      end
      assert_equal("", @event);
      assert_raise(WIN32OLERuntimeError) {
        ev.on_event {|*args| default_handler(*args)}
      }
    end
Register or log in to add new notes.