Sha256: f7c052a666e937f977cfe640eef00deac32efea6823b45dc96e07fc92f5f5ace

Contents?: true

Size: 397 Bytes

Versions: 5

Compression:

Stored size: 397 Bytes

Contents

require 'anise/annotator'

include Anise::Annotator

class Test_Annotator_Toplevel < Test::Unit::TestCase

  class X
    annotator :req

    req 'r'

    def a ; "a"; end

    req 's'

    attr :b
  end

  def test_annotated
    assert_equal( {:req=>['r']}, X.ann(:a) )
  end

  def test_annotated
    assert_equal( {:req=>['s']}, X.ann(:b) )
  end

end

#annotator :req  # THIS DOES NOT WORK :(

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
anise-0.4.0 test/test_annotator_toplevel.rb
anise-0.2.0 test/test_annotator_toplevel.rb
anise-0.2.1 test/test_annotator_toplevel.rb
anise-0.2.2 test/test_annotator_toplevel.rb
anise-0.3.0 test/test_annotator_toplevel.rb