private
.
.
.
# Kilka asercji narzdziowych dla testowania HTML

# Sprawdza, czy pole email ma poprawny HTML
def assert_email_field(email = nil, options = {})
  assert_input_field("user[email]", email, "text",
                   User::EMAIL_SIZE, User::EMAIL_MAX_LENGTH,
                   options)
end

# Sprawdza, czy pole hasa (password) ma poprawny HTML
def assert_password_field(password_field_name = "password", options = {})
  # Nie chcemy, aby haso byo ponownie wywietlane w formularzu
  blank = nil
  assert_input_field("user[#{password_field_name}]", blank, "password",
                      User::PASSWORD_SIZE, User::PASSWORD_MAX_LENGTH,
                      options)
end

# Sprawdza, czy pole pseudonimu (screen_name) ma poprawny HTML
def assert_screen_name_field(screen_name = nil, options = {})
  assert_input_field("user[screen_name]", screen_name, "text",
                      User::SCREEN_NAME_SIZE, User::SCREEN_NAME_MAX_LENGTH,
                      options)
end

