cloud_controller/spec/support/cloud_spec_helpers.rb
def build_admin_and_user
    User.admins = %w[admin@example.com]
    @admin_password ||= "ADMINpassword" if @admin.nil?
    @admin ||= build_user(User.admins.first, @admin_password)
    @user_password ||= "USERpassword" if @user.nil?
    @user ||= build_user('user@example.com', @user_password)
  end
# Expected to be called in a 'before' block. Ensures that there are at least two users, one an admin.
Expected to be called in a 'before' block. Ensures that there are at least two users, one an admin.
Expected to be called in a ' before ' block . Ensures that there are at least two users one an admin .
def build_admin_and_user
    User.admins = %w[admin@example.com]
    @admin_password ||= "ADMINpassword" if @admin.nil?
    @admin ||= build_user(User.admins.first, @admin_password)
    @user_password ||= "USERpassword" if @user.nil?
    @user ||= build_user('user@example.com', @user_password)
  end
def build_admin_and_user User . admins = %w[ admin@example.com ] @admin_password ||= "ADMINpassword" if @admin . nil? @admin ||= build_user ( User . admins . first , @admin_password ) @user_password ||= "USERpassword" if @user . nil? @user ||= build_user ( 'user@example.com' , @user_password ) end
Expected to be called in a 'before' block.
Expected to be called in a ' before ' block .