<commit_before>require File.dirname(__FILE__) + '/../../spec_helper'
require File.dirname(__FILE__) + '/fixtures/classes'

describe "Thread#[]=" do
  it "raises exceptions on the wrong type of keys" do
    lambda { Thread.current[nil] = true }.should raise_error(TypeError)
    lambda { Thread.current[5] = true }.should raise_error(ArgumentError)
  end
end<commit_msg>Thread#[]=: 1.9 raises TypeError for invalid keys.<commit_after>require File.dirname(__FILE__) + '/../../spec_helper'
require File.dirname(__FILE__) + '/fixtures/classes'

describe "Thread#[]=" do
  ruby_version_is ""..."1.9.1" do
    it "raises exceptions on the wrong type of keys" do
      lambda { Thread.current[nil] = true }.should raise_error(TypeError)
      lambda { Thread.current[5] = true }.should raise_error(ArgumentError)
    end
  end

  ruby_version_is "1.9.1" do
    it "raises exceptions on the wrong type of keys" do
      lambda { Thread.current[nil] = true }.should raise_error(TypeError)
      lambda { Thread.current[5] = true }.should raise_error(TypeError)
    end
  end
end
{'fraction_non_alphanumeric': 0.13096351730589337, 'fraction_numerical': 0.01028999064546305, 'mean_word_length': 3.908256880733945, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5876558', 'n_tokens_mistral': 339, 'n_tokens_neox': 332, 'n_words': 96}