Class: Spec::Matchers::Migration::NullableColumnMatcher
- Defined in:
- lib/gems/dm-migrations-0.9.9/lib/spec/matchers/migration_matchers.rb
Instance Attribute Summary collapse
-
#column ⇒ Object
Returns the value of attribute column.
Instance Method Summary collapse
Instance Attribute Details
#column ⇒ Object
Returns the value of attribute column.
69 70 71 |
# File 'lib/gems/dm-migrations-0.9.9/lib/spec/matchers/migration_matchers.rb', line 69 def column @column end |
Instance Method Details
#failure_message ⇒ Object
76 77 78 |
# File 'lib/gems/dm-migrations-0.9.9/lib/spec/matchers/migration_matchers.rb', line 76 def %(expected #{column.name} to permit NULL) end |
#matches?(column) ⇒ Boolean
71 72 73 74 |
# File 'lib/gems/dm-migrations-0.9.9/lib/spec/matchers/migration_matchers.rb', line 71 def matches?(column) @column = column ! column.not_null end |
#negative_failure_message ⇒ Object
80 81 82 |
# File 'lib/gems/dm-migrations-0.9.9/lib/spec/matchers/migration_matchers.rb', line 80 def %(expected #{column.name} to be NOT NULL) end |