<commit_before>require 'yelp'

describe Yelp::Client::Search do
  let(:keys) { Hash[consumer_key: 'abc',
                    consumer_secret: 'def',
                    token: 'ghi',
                    token_secret: 'jkl'] }
  let(:location) { 'San Francisco' }
  let(:params) { Hash[term: 'restaurants',
                      category_filter: 'discgolf'] }

  before do
    @client = Yelp::Client.new(keys)
    @client.authorize
  end

  describe 'inheritance' do
    it 'should get @access_token from search' do
      @client.send(:search_access_token).should eql @client.access_token
    end
  end<commit_msg>Use ENV for api keys in testing<commit_after>require 'yelp'

describe Yelp::Client::Search do
  let(:keys) { Hash[consumer_key: ENV['YELP_CONSUMER_KEY'],
                    consumer_secret: ENV['YELP_CONSUMER_SECRET'],
                    token: ENV['YELP_TOKEN'],
                    token_secret: ENV['YELP_TOKEN_SECRET']] }
  let(:location) { 'San Francisco' }
  let(:params) { Hash[term: 'restaurants',
                      category_filter: 'discgolf'] }

  before do
    @client = Yelp::Client.new(keys)
    @client.authorize
  end

  describe 'inheritance' do
    it 'should get @access_token from search' do
      @client.send(:search_access_token).should eql @client.access_token
    end
  end
{'fraction_non_alphanumeric': 0.11854103343465046, 'fraction_numerical': 0.0, 'mean_word_length': 2.689075630252101, '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': '1859493', 'n_tokens_mistral': 439, 'n_tokens_neox': 416, 'n_words': 91}