Sha256: de02307671fe25e4b908d14e06918998520de5012cc7c967400b9545e8b07657
Contents?: true
Size: 625 Bytes
Versions: 6
Compression:
Stored size: 625 Bytes
Contents
require 'test/unit' require 'wx' class TestingFrame < Wx::Frame def initialize super(nil, -1, '') evt_paint { on_paint } end def on_paint paint {} close end end class AppWithSimpleFrame < Wx::App attr_reader(:did_call_on_exit) def on_init TestingFrame.new.show end def on_exit @did_call_on_exit = true return 0 end end class TestApp < Test::Unit::TestCase def test_self_closing_frame o = AppWithSimpleFrame.new o.run assert(o.did_call_on_exit, "didn't call on_exit?") end end
Version data entries
6 entries across 6 versions & 1 rubygems