Sha256: db516fa0f95f322e20fd553d1e0e9e45dcf55b10ec507254510ee35e2848ad78

Contents?: true

Size: 557 Bytes

Versions: 221

Compression:

Stored size: 557 Bytes

Contents

require File.join(File.dirname(__FILE__), '../test_helper.rb')

class ActionsTest < Test::Unit::TestCase
  def setup
    @actions = ActiveScaffold::DataStructures::Actions.new(:a, 'b')
  end

  def test_initialization
    assert @actions.include?('a')
    assert @actions.include?(:b)
    assert !@actions.include?(:c)
  end

  def test_exclude
    assert @actions.include?('b')
    @actions.exclude :b
    assert !@actions.include?(:b)
  end

  def test_add
    assert !@actions.include?(:c)
    @actions.add 'c'
    assert @actions.include?('c')
  end
end

Version data entries

221 entries across 221 versions & 8 rubygems

Version Path
active_scaffold-3.2.3 test/data_structures/actions_test.rb
active_scaffold-sequel-0.5.1 test/data_structures/actions_test.rb
active_scaffold-sequel-0.5.0 test/data_structures/actions_test.rb
active_scaffold-3.2.2 test/data_structures/actions_test.rb
active_scaffold-3.2.1 test/data_structures/actions_test.rb
active_scaffold-sequel-0.4.0 test/data_structures/actions_test.rb
active_scaffold_vho-3.0.25 test/data_structures/actions_test.rb
active_scaffold-sequel-0.3.0 test/data_structures/actions_test.rb
active_scaffold-3.2.0 test/data_structures/actions_test.rb
active_scaffold_vho-3.1.3 test/data_structures/actions_test.rb
active_scaffold_vho-3.1.2 test/data_structures/actions_test.rb
active_scaffold-3.1.20 test/data_structures/actions_test.rb
active_scaffold-3.1.19 test/data_structures/actions_test.rb
active_scaffold-3.1.18 test/data_structures/actions_test.rb
active_scaffold-3.1.17 test/data_structures/actions_test.rb
active_scaffold-3.1.15 test/data_structures/actions_test.rb
active_scaffold-3.1.14 test/data_structures/actions_test.rb
active_scaffold-3.0.26 test/data_structures/actions_test.rb
active_scaffold_vho-3.1.1 test/data_structures/actions_test.rb
active_scaffold-3.1.13 test/data_structures/actions_test.rb