<commit_before>require 'spec_helper'

describe Citygate::User do

  before(:each) do
    @attr = { 
      :first_name            => "User",
      :email                 => "<EMAIL>",
      :password              => "<PASSWORD>",
      :password_confirmation => "<PASSWORD>"
    }
  end

  it "should render the correct json hash" do
    fb_user = Factory.create(:facebook_user)
    fb_user.as_json.should == {
      :name        => "User",
      :email       => "<EMAIL>",
      :link        => "http://www.facebook.com/luis.zamith",
      :image       => "http://graph.facebook.com/754864768/picture?type=square"
    }
  end

  it "should create a new instance given a valid attribute" do
    Citygate::User.create!(@attr)
  end

  it "should require an email address" do<commit_msg>More password changes<commit_after>require 'spec_helper'

describe Citygate::User do

  before(:each) do
    @attr = { 
      :first_name            => "User",
      :email                 => "<EMAIL>",
      :password              => "<PASSWORD>",
      :password_confirmation => "<PASSWORD>"
    }
  end

  it "should render the correct json hash" do
    fb_user = Factory.create(:facebook_user)
    fb_user.as_json.should == {
      :name        => "User",
      :email       => "<EMAIL>",
      :link        => "http://www.facebook.com/luis.zamith",
      :image       => "http://graph.facebook.com/754864768/picture?type=square"
    }
  end

  it "should create a new instance given a valid attribute" do
    Citygate::User.create!(@attr)
  end

  it "should require an email address" do
{'fraction_non_alphanumeric': 0.13705583756345177, 'fraction_numerical': 0.011421319796954314, 'mean_word_length': 2.1987829614604464, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 27, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1540158', 'n_tokens_mistral': 503, 'n_tokens_neox': 476, 'n_words': 115}