<commit_before>require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
require 'timecop'

describe Panda do
  before(:each) do
    new_time = Time.local(20010, 1, 12, 1, 0, 0)
    Timecop.freeze(new_time)
  end
  
  describe "when not connected" do
    
    ["get", "post", "put", "delete"].each do |method|
      it "should raise error for #{method}" do
        lambda {
          Panda.send(method, nil, nil)
        }.should raise_error("Panda is not configured!")
      end
    end
    
  end

  shared_examples_for "Connected" do
<commit_msg>Fix: use utc time in the spec<commit_after>require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
require 'timecop'

describe Panda do
  before(:each) do
    new_time = Time.utc(20010, 1, 12, 1, 0, 0)
    Timecop.freeze(new_time)
  end
  
  describe "when not connected" do
    
    ["get", "post", "put", "delete"].each do |method|
      it "should raise error for #{method}" do
        lambda {
          Panda.send(method, nil, nil)
        }.should raise_error("Panda is not configured!")
      end
    end
    
  end

  shared_examples_for "Connected" do

{'fraction_non_alphanumeric': 0.12145390070921985, 'fraction_numerical': 0.01950354609929078, 'mean_word_length': 2.879725085910653, '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': '3054181', 'n_tokens_mistral': 404, 'n_tokens_neox': 377, 'n_words': 110}