File: understandable_test.rb

package info (click to toggle)
ruby-validatable 1.6.7-11
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 284 kB
  • sloc: ruby: 1,636; makefile: 10
file content (19 lines) | stat: -rw-r--r-- 428 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
require File.expand_path(File.dirname(__FILE__) + '/../test_helper')

Expectations do
  expect [:c, :b, :a] do
    a = Class.new do
      include Validatable::Understandable
      understands :a
    end
    b = Class.new(a) do
      include Validatable::Understandable
      understands :b
    end
    c = Class.new(b) do
      include Validatable::Understandable
      understands :c
    end
    c.all_understandings
  end
end