<commit_before>require 'smoke_spec_helper.rb'

describe "signing petitions" do
  before(:all) do
    @petition = create_a_petition
    set_default_experiment_results
  end
  describe "showing the thermometer" do
    it "should be visible" do
      go_to petition_path(@petition)
      element_exists(class: "progress_bar").should be_true
    end

  end

  describe "signing the petition" do
    it "should show seperate fields for entering first and last names" do
      force_result("full name vs first and last name" => "firstandlastname")

      go_to petition_path(@petition)
      element_exists(id: "signature_name").should be_false
      element_exists(id: 'signature_first_name').should be_true
      element_exists(id: 'signature_last_name').should be_true
    end
  end

    #full (I think) list of experiments that affect layout:
    #
    #"facebook sharing options" => "facebook_like",
    #"signature display threshold" => 0,
    #"show thermometer" => 'true',
    #"seed signatures with petition creator" => "false",
    #"toggle showing vs. not showing modal" => 'false',
    #"change layouts" => "bootstrap",
end

<commit_msg>remove line forcing experiment result for nonexisting experiment<commit_after>require 'smoke_spec_helper.rb'

describe "signing petitions" do
  before(:all) do
    @petition = create_a_petition
    set_default_experiment_results
  end
  describe "showing the thermometer" do
    it "should be visible" do
      go_to petition_path(@petition)
      element_exists(class: "progress_bar").should be_true
    end

  end

  describe "signing the petition" do
    it "should show seperate fields for entering first and last names" do

      go_to petition_path(@petition)
      element_exists(id: "signature_name").should be_false
      element_exists(id: 'signature_first_name').should be_true
      element_exists(id: 'signature_last_name').should be_true
    end
  end

    #full (I think) list of experiments that affect layout:
    #
    #"facebook sharing options" => "facebook_like",
    #"signature display threshold" => 0,
    #"show thermometer" => 'true',
    #"seed signatures with petition creator" => "false",
    #"toggle showing vs. not showing modal" => 'false',
    #"change layouts" => "bootstrap",
end


{'fraction_non_alphanumeric': 0.09469026548672567, 'fraction_numerical': 0.0008849557522123894, 'mean_word_length': 3.8833693304535637, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 16, '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': '6119573', 'n_tokens_mistral': 681, 'n_tokens_neox': 650, 'n_words': 207}