<commit_before>require 'test_helper'

class ApplicantTest < ActiveSupport::TestCase
  def setup
    @one = applicants(:one)
    @two = applicants(:two)
  end

  test "responds to form field values" do
    assert_equal "<NAME>", @one.field("FullName")
    assert_equal "<NAME>", @one.field("FullName1")
    assert_equal "(202) 586-5000", @one.field("WorkPhone")
    assert_equal "", @one.field("AddressApt")
    assert_equal "", @one.field("AddressCity")
    assert_equal "", @one.field("AddressState")
    assert_equal "", @one.field("AddressStreet")
    assert_equal "", @one.field("AddressZip")
    assert_equal "", @one.field("Age")
    assert_equal "", @one.field("Citizen")
    assert_equal "", @one.field("DOB")
    assert_equal "", @one.field("Email")
    assert_equal "", @one.field("FirstName")
    assert_equal "", @one.field("LastName")
    assert_equal "", @one.field("Name")
    assert_equal "(202) 208-4743", @one.field("CellPhone")
    assert_equal "(202) 272-0167", @one.field("HomePhone")
    assert_equal "(202) 456-1111", @one.field("Phone")
    assert_equal "", @one.field("SSN")
    assert_equal "", @one.field("Gender")
    assert_equal "", @one.field("GenderInitial")
    assert_equal "", @one.field("ResAddApt")
    assert_equal "", @one.field("ResAddCity")
    assert_equal "", @one.field("ResAddState")
    assert_equal "", @one.field("ResAddStreet")
    assert_equal "", @one.field("ResAddZip")

    assert_equal "", @one.field("Accommodations")
    assert_equal "", @one.field("Accommodations2")
    assert_equal "", @one.field("AlimonyN")
    assert_equal "", @one.field("AlimonyY")
    assert_equal "", @one.field("Arabic")
    assert_equal "", @one.field("Armenian")
    assert_equal "", @one.field("AssetsIncN")
    assert_equal "", @one.field("AssetsIncY")
    assert_equal "", @one.field("BankNameCheck")
    assert_equal "", @one.field("BankNameOth")
    assert_equal "", @one.field("BankNameSav")
    assert_equal "", @one.field("Cambodian")
    assert_equal "", @one.field("CashGiftsN")
    assert_equal "", @one.field("CashGiftsY")
    assert_equal "", @one.field("Chamorro")
    assert_equal "", @one.field("CheckingAcct")
    assert_equal "", @one.field("CheckingBalance")
    assert_equal "", @one.field("ChildSupIncN")
    assert_equal "", @one.field("ChildSupIncY")
    assert_equal "", @one.field("ChineseSimp")
    assert_equal "", @one.field("ChineseTrad")
    assert_equal "", @one.field("CitYN")
    assert_equal "", @one.field("ConvictionsN")
    assert_equal "", @one.field("Croatian")
    assert_equal "", @one.field("Czech")
    assert_equal "", @one.field("Disability")
    assert_equal "", @one.field("Dutch")
    assert_equal "", @one.field("EmpIncN")
    assert_equal "", @one.field("EmpIncY")
    assert_equal "", @one.field("English")
    assert_equal "", @one.field("EthnicityDeclineT")
    assert_equal "", @one.field("EthnicityHispanic")
    assert_equal "", @one.field("EthnicityHispanicT")
    assert_equal "", @one.field("EthnicityNonHispanic")
    assert_equal "", @one.field("EthnicityNonHispanicT")
    assert_equal "", @one.field("EvictDrugsN")
    assert_equal "", @one.field("EvictDrugsY")
    assert_equal "", @one.field("Farsi")
    assert_equal "", @one.field("French")
    assert_equal "", @one.field("German")
    assert_equal "", @one.field("Greek")

    assert_equal "", @one.field("Contact1Add")
    assert_equal "", @one.field("Contact1Address")
    assert_equal "", @one.field("Contact1CellPhone")
    assert_equal "", @one.field("Contact1Name")
    assert_equal "", @one.field("Contact1Phone")
    assert_equal "", @one.field("Contact1Relationship")
    assert_equal "", @one.field("Contact2Add")
    assert_equal "", @one.field("Contact2Name")
    assert_equal "", @one.field("Contact2Phone")

    assert_equal "", @one.field("HH1Age")
    assert_equal "", @one.field("HH1CitizenYN")
    assert_equal "", @one.field("HH1DOB")
    assert_equal "", @one.field("HH1FirstName")
    assert_equal "", @one.field("HH1Gender")
    assert_equal "", @one.field("HH1LastName")
    assert_equal "", @one.field("HH1Name")
    assert_equal "", @one.field("HH1Relationship")
    assert_equal "", @one.field("HH1SSN")
    assert_equal "", @one.field("HH2Age")
    assert_equal "", @one.field("HH2CitizenYN")
    assert_equal "", @one.field("HH2DOB")
    assert_equal "", @one.field("HH2FirstName")
    assert_equal "", @one.field("HH2Gender")
    assert_equal "", @one.field("HH2LastName")
    assert_equal "", @one.field("HH2Name")
    assert_equal "", @one.field("HH2Relationship")
    assert_equal "", @one.field("HH2SSN")
    assert_equal "", @one.field("HH3Age")
    assert_equal "", @one.field("HH3CitizenYN")
    assert_equal "", @one.field("HH3DOB")
    assert_equal "", @one.field("HH3FirstName")
    assert_equal "", @one.field("HH3Gender")
    assert_equal "", @one.field("HH3LastName")
    assert_equal "", @one.field("HH3Name")
    assert_equal "", @one.field("HH3Relationship")
    assert_equal "", @one.field("HH3SSN")
    assert_equal "", @one.field("HH4Age")
    assert_equal "", @one.field("HH4CitizenYN")
    assert_equal "", @one.field("HH4DOB")
    assert_equal "", @one.field("HH4FirstName")
    assert_equal "", @one.field("HH4Gender")
    assert_equal "", @one.field("HH4LastName")
    assert_equal "", @one.field("HH4Name")
    assert_equal "", @one.field("HH4Relationship")
    assert_equal "", @one.field("HH4SSN")
    assert_equal "", @one.field("HH5Age")
    assert_equal "", @one.field("HH5CitizenYN")
    assert_equal "", @one.field("HH5DOB")
    assert_equal "", @one.field("HH5FirstName")
    assert_equal "", @one.field("HH5Gender")
    assert_equal "", @one.field("HH5LastName")
    assert_equal "", @one.field("HH5Name")
    assert_equal "", @one.field("HH5Relationship")
    assert_equal "", @one.field("HH5SSN")

    assert_equal "", @one.field("LL1Address")
    assert_equal "", @one.field("LL1Name")
    assert_equal "", @one.field("LL1Phone")
    assert_equal "", @one.field("LL2Address")
    assert_equal "", @one.field("LL2Name")
    assert_equal "", @one.field("LL2Phone")

    assert_equal "", @one.field("Haitian")
    assert_equal "", @one.field("Hindi")
    assert_equal "", @one.field("Hmong")
    assert_equal "", @one.field("Hungarian")
    assert_equal "", @one.field("Ilocano")
    assert_equal "", @one.field("Italian")
    assert_equal "", @one.field("Japanese")
    assert_equal "", @one.field("Korean")
    assert_equal "", @one.field("LPR")
    assert_equal "", @one.field("Laotian")
    assert_equal "", @one.field("LiveWithYou")
    assert_equal "", @one.field("LiveWithYouN")
    assert_equal "", @one.field("LiveWithYouY")
    assert_equal "", @one.field("MCareN")
    assert_equal "", @one.field("MCareY")
    assert_equal "", @one.field("MailAddress")
    assert_equal "", @one.field("Nationality")
    assert_equal "", @one.field("NonCit")
    assert_equal "", @one.field("OtherAcct")
    assert_equal "", @one.field("OtherBalance")
    assert_equal "", @one.field("OutstandingBillsN")<commit_msg>Reorder applicant tests some more<commit_after>require 'test_helper'

class ApplicantTest < ActiveSupport::TestCase
  def setup
    @one = applicants(:one)
    @two = applicants(:two)
  end

  test "fills basic personal information" do
    assert_equal "<NAME>", @one.field("FullName")
    assert_equal "<NAME>", @one.field("FullName1")
    assert_equal "(202) 586-5000", @one.field("WorkPhone")
    assert_equal "", @one.field("Age")
    assert_equal "", @one.field("Citizen")
    assert_equal "1981-01-01 01:01:01 UTC", @one.field("DOB")
    assert_equal "", @one.field("Email")
    assert_equal "One", @one.field("FirstName")
    assert_equal "McOne", @one.field("LastName")
    assert_equal "<NAME>", @one.field("Name")
    assert_equal "(202) 208-4743", @one.field("CellPhone")
    assert_equal "(202) 272-0167", @one.field("HomePhone")
    assert_equal "(202) 456-1111", @one.field("Phone")
    assert_equal "111-11-1111", @one.field("SSN")
    assert_equal "", @one.field("Gender")
    assert_equal "", @one.field("GenderInitial")
    assert_equal "", @one.field("Nationality")
    assert_equal "", @one.field("NonCit")
  end

  test "fills addresses" do
    assert_equal "", @one.field("AddressApt")
    assert_equal "", @one.field("AddressCity")
    assert_equal "", @one.field("AddressState")
    assert_equal "", @one.field("AddressStreet")
    assert_equal "", @one.field("AddressZip")
    assert_equal "", @one.field("MailAddress")
    assert_equal "", @one.field("ResAddApt")
    assert_equal "", @one.field("ResAddCity")
    assert_equal "", @one.field("ResAddState")
    assert_equal "", @one.field("ResAddStreet")
    assert_equal "", @one.field("ResAddZip")
  end

  test "fills contact information" do
    assert_equal "", @one.field("Contact1Add")
    assert_equal "", @one.field("Contact1Address")
    assert_equal "", @one.field("Contact1CellPhone")
    assert_equal "", @one.field("Contact1Name")
    assert_equal "", @one.field("Contact1Phone")
    assert_equal "", @one.field("Contact1Relationship")
    assert_equal "", @one.field("Contact2Add")
    assert_equal "", @one.field("Contact2Name")
    assert_equal "", @one.field("Contact2Phone")
  end

  test "fills household member information" do
    assert_equal "", @one.field("HH1Age")
    assert_equal "", @one.field("HH1CitizenYN")
    assert_equal "", @one.field("HH1DOB")
    assert_equal "", @one.field("HH1FirstName")
    assert_equal "", @one.field("HH1Gender")
    assert_equal "", @one.field("HH1LastName")
    assert_equal "", @one.field("HH1Name")
    assert_equal "", @one.field("HH1Relationship")
    assert_equal "", @one.field("HH1SSN")
    assert_equal "", @one.field("HH2Age")
    assert_equal "", @one.field("HH2CitizenYN")
    assert_equal "", @one.field("HH2DOB")
    assert_equal "", @one.field("HH2FirstName")
    assert_equal "", @one.field("HH2Gender")
    assert_equal "", @one.field("HH2LastName")
    assert_equal "", @one.field("HH2Name")
    assert_equal "", @one.field("HH2Relationship")
    assert_equal "", @one.field("HH2SSN")
    assert_equal "", @one.field("HH3Age")
    assert_equal "", @one.field("HH3CitizenYN")
    assert_equal "", @one.field("HH3DOB")
    assert_equal "", @one.field("HH3FirstName")
    assert_equal "", @one.field("HH3Gender")
    assert_equal "", @one.field("HH3LastName")
    assert_equal "", @one.field("HH3Name")
    assert_equal "", @one.field("HH3Relationship")
    assert_equal "", @one.field("HH3SSN")
    assert_equal "", @one.field("HH4Age")
    assert_equal "", @one.field("HH4CitizenYN")
    assert_equal "", @one.field("HH4DOB")
    assert_equal "", @one.field("HH4FirstName")
    assert_equal "", @one.field("HH4Gender")
    assert_equal "", @one.field("HH4LastName")
    assert_equal "", @one.field("HH4Name")
    assert_equal "", @one.field("HH4Relationship")
    assert_equal "", @one.field("HH4SSN")
    assert_equal "", @one.field("HH5Age")
    assert_equal "", @one.field("HH5CitizenYN")
    assert_equal "", @one.field("HH5DOB")
    assert_equal "", @one.field("HH5FirstName")
    assert_equal "", @one.field("HH5Gender")
    assert_equal "", @one.field("HH5LastName")
    assert_equal "", @one.field("HH5Name")
    assert_equal "", @one.field("HH5Relationship")
    assert_equal "", @one.field("HH5SSN")
  end

  test "fills landlord information" do
    assert_equal "", @one.field("LL1Address")
    assert_equal "", @one.field("LL1Name")
    assert_equal "", @one.field("LL1Phone")
    assert_equal "", @one.field("LL2Address")
    assert_equal "", @one.field("LL2Name")
    assert_equal "", @one.field("LL2Phone")
  end

  test "other fields" do
    assert_equal "", @one.field("Accommodations")
    assert_equal "", @one.field("Accommodations2")
    assert_equal "", @one.field("AlimonyN")
    assert_equal "", @one.field("AlimonyY")
    assert_equal "", @one.field("Arabic")
    assert_equal "", @one.field("Armenian")
    assert_equal "", @one.field("AssetsIncN")
    assert_equal "", @one.field("AssetsIncY")
    assert_equal "", @one.field("BankNameCheck")
    assert_equal "", @one.field("BankNameOth")
    assert_equal "", @one.field("BankNameSav")
    assert_equal "", @one.field("Cambodian")
    assert_equal "", @one.field("CashGiftsN")
    assert_equal "", @one.field("CashGiftsY")
    assert_equal "", @one.field("Chamorro")
    assert_equal "", @one.field("CheckingAcct")
    assert_equal "", @one.field("CheckingBalance")
    assert_equal "", @one.field("ChildSupIncN")
    assert_equal "", @one.field("ChildSupIncY")
    assert_equal "", @one.field("ChineseSimp")
    assert_equal "", @one.field("ChineseTrad")
    assert_equal "", @one.field("CitYN")
    assert_equal "", @one.field("ConvictionsN")
    assert_equal "", @one.field("Croatian")
    assert_equal "", @one.field("Czech")
    assert_equal "", @one.field("Disability")
    assert_equal "", @one.field("Dutch")
    assert_equal "", @one.field("EmpIncN")
    assert_equal "", @one.field("EmpIncY")
    assert_equal "", @one.field("English")
    assert_equal "", @one.field("EthnicityDeclineT")
    assert_equal "", @one.field("EthnicityHispanic")
    assert_equal "", @one.field("EthnicityHispanicT")
    assert_equal "", @one.field("EthnicityNonHispanic")
    assert_equal "", @one.field("EthnicityNonHispanicT")
    assert_equal "", @one.field("EvictDrugsN")
    assert_equal "", @one.field("EvictDrugsY")
    assert_equal "", @one.field("Farsi")
    assert_equal "", @one.field("French")
    assert_equal "", @one.field("German")
    assert_equal "", @one.field("Greek")
    assert_equal "", @one.field("Haitian")
    assert_equal "", @one.field("Hindi")
    assert_equal "", @one.field("Hmong")
    assert_equal "", @one.field("Hungarian")
    assert_equal "", @one.field("Ilocano")
    assert_equal "", @one.field("Italian")
    assert_equal "", @one.field("Japanese")
    assert_equal "", @one.field("Korean")
    assert_equal "", @one.field("LPR")
    assert_equal "", @one.field("Laotian")
    assert_equal "", @one.field("LiveWithYou")
    assert_equal "", @one.field("LiveWithYouN")
    assert_equal "", @one.field("LiveWithYouY")
    assert_equal "", @one.field("MCareN")
    assert_equal "", @one.field("MCareY")
    assert_equal "", @one.field("OtherAcct")
    assert_equal "", @one.field("OtherBalance")
    assert_equal "", @one.field("OutstandingBillsN")
{'fraction_non_alphanumeric': 0.1921305985768104, 'fraction_numerical': 0.015836472722198968, 'mean_word_length': 4.6727344677483185, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, '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': '1525462', 'n_tokens_mistral': 4974, 'n_tokens_neox': 4763, 'n_words': 688}