method

assert_blank

rails latest stable - Class: ActiveSupport::Testing::Assertions

Method deprecated or moved

This method is deprecated or moved on the latest stable version. The last existing version (v4.0.2) is shown here.

assert_blank(object, message=nil)
public

Test if an expression is blank. Passes if object.blank? is true.

assert_blank []   # => true
assert_blank [[]] # => [[]] is not blank

An error message can be specified.

assert_blank [], 'this should be blank'