Sha256: d48f0965171caf754b28e22b692cd2821c39da66c658fa95d924336466c1f585

Contents?: true

Size: 1.31 KB

Versions: 56

Compression:

Stored size: 1.31 KB

Contents

require 'test/unit'
require 'testcase'
require 'fox16'

class TC_FXCheckButton < Fox::TestCase
  include Fox

  def setup
    super("TC_FXCheckButton")
    @checkButton = FXCheckButton.new(mainWindow, "cbText")
  end

  def test_setCheck_TRUE
    @checkButton.check = Fox::TRUE
    assert_equal(Fox::TRUE, @checkButton.checkState)
    assert(@checkButton.checked?)
    assert(!@checkButton.unchecked?)
    assert(!@checkButton.maybe?)
  end

  def test_setCheck_FALSE
    @checkButton.check = Fox::FALSE
    assert_equal(Fox::FALSE, @checkButton.checkState)
    assert(!@checkButton.checked?)
    assert(@checkButton.unchecked?)
    assert(!@checkButton.maybe?)
  end

  def test_setCheck_MAYBE
    @checkButton.check = Fox::MAYBE
    assert_equal(Fox::MAYBE, @checkButton.checkState)
    assert(!@checkButton.checked?)
    assert(!@checkButton.unchecked?)
    assert(@checkButton.maybe?)
  end

  def test_setCheck_true
    @checkButton.check = true
    assert_equal(Fox::TRUE, @checkButton.checkState)
    assert(@checkButton.checked?)
    assert(!@checkButton.unchecked?)
    assert(!@checkButton.maybe?)
  end

  def test_setCheck_false
    @checkButton.check = false
    assert_equal(Fox::FALSE, @checkButton.checkState)
    assert(!@checkButton.checked?)
    assert(@checkButton.unchecked?)
    assert(!@checkButton.maybe?)
  end
end

Version data entries

56 entries across 56 versions & 1 rubygems

Version Path
fxruby-1.6.37-x86-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.37.rc1 test/TC_FXCheckButton.rb
fxruby-1.6.37.rc1-x64-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.37.rc1-x86-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.36 test/TC_FXCheckButton.rb
fxruby-1.6.36-x64-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.36-x86-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.35-x86-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.35-x64-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.35 test/TC_FXCheckButton.rb
fxruby-1.6.34-x86-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.34-x64-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.34 test/TC_FXCheckButton.rb
fxruby-1.6.33-x86-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.33-x64-mingw32 test/TC_FXCheckButton.rb
fxruby-1.6.33 test/TC_FXCheckButton.rb