# == Schema Information
#
# Table name: users
#
#  id                     :bigint           not null, primary key
#  email                  :string           default(""), not null
#  encrypted_password     :string           default(""), not null
#  reset_password_token   :string
#  reset_password_sent_at :datetime
#  remember_created_at    :datetime
#  sign_in_count          :integer          default(0), not null
#  current_sign_in_at     :datetime
#  last_sign_in_at        :datetime
#  current_sign_in_ip     :string
#  last_sign_in_ip        :string
#  created_at             :datetime         not null
#  updated_at             :datetime         not null
#  firstname              :string
#  lastname               :string
#  confirmation_token     :string
#  confirmed_at           :datetime
#  confirmation_sent_at   :datetime
#  unconfirmed_email      :string
#  provider               :string
#  uid                    :string
#  token                  :string
#  expires_at             :integer
#  expires                :boolean
#  refresh_token          :string
#

require 'test_helper'

class UserTest < ActiveSupport::TestCase

  test 'creates a new user and all associated objects' do 
    assert_difference 'User.count', 1 do 
      User.create!(email: 'test@email.com', password: 'Password1!')
    end
    assert_equal 'test@email.com', User.last.email
  end
end
