<commit_before>require 'spec_helper'
require 'json'
require './lib/marver.rb'

describe Marver::Event do

  let(:credentials) { Marver::Credentials.new("pub_key", "priv_key") }
  let(:event) { Marver::Event.new({ "resourceURI" => "http://gateway.marvel.com/v1/public/events/116", "name" => "Acts of Vengeance!"}, credentials) }

  it "#name - The title of the event." do
    expect(event.name).to eq "Acts of Vengeance!"
  end

  it "#resourceURI - The canonical URL identifier for this resource." do
    Time.stub_chain(:now, :to_i, :to_s).and_return "1"
    expect(event.resource_uri).to eq "http://gateway.marvel.com/v1/public/events/116?ts=1&apikey=pub_key&hash=3d4ce88a477c7e4a5accbf6cd2c8b819"
  end
end
<commit_msg>fix event spec<commit_after>require 'spec_helper'
require 'json'
require './lib/marver.rb'

describe Marver::Event do

  let(:credentials) { Marver::Credentials.new("pub_key", "priv_key") }
  let(:event) { Marver::Event.new({ "resourceURI" => "http://gateway.marvel.com/v1/public/events/116", "name" => "Acts of Vengeance!"}, credentials) }

  it "#name - The title of the event." do
    expect(event.name).to eq "Acts of Vengeance!"
  end

  it "#resourceURI - The canonical URL identifier for this resource." do
    Time.stub_chain(:now, :to_i, :to_s).and_return "1"
    expect(event.resource_uri).to eq "http://gateway.marvel.com/v1/public/events/116?ts=1&apikey=priv_key&hash=668dea517c974c12d8d0193cf2d8f7f7"
  end
end

{'fraction_non_alphanumeric': 0.1590594744121715, 'fraction_numerical': 0.03872752420470263, 'mean_word_length': 4.8582995951417, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '2751642', 'n_tokens_mistral': 566, 'n_tokens_neox': 537, 'n_words': 110}