<commit_before>require 'spec_helper'

describe OAuth2::Strategy::WebServer do
  let(:client) do
    cli = OAuth2::Client.new('abc', 'def', :site => 'http://api.example.com')
    cli.connection.build do |b|
      b.adapter :test do |stub|
        stub.post('/oauth/access_token') do |env|
          case @mode
            when "formencoded"
              [200, {}, 'expires_in=600&access_token=salmon&refresh_token=trout&extra_param=steve']
            when "json"
              [200, {}, '{"expires_in":600,"access_token":"salmon","refresh_token":"trout","extra_param":"steve"}']
            when "from_facebook"
              [200, {}, 'expires=600&access_token=salmon&refresh_token=trout&extra_param=steve']
          end
        end<commit_msg>Fix indentation<commit_after>require 'spec_helper'

describe OAuth2::Strategy::WebServer do
  let(:client) do
    cli = OAuth2::Client.new('abc', 'def', :site => 'http://api.example.com')
    cli.connection.build do |b|
      b.adapter :test do |stub|
        stub.post('/oauth/access_token') do |env|
          case @mode
          when "formencoded"
            [200, {}, 'expires_in=600&access_token=salmon&refresh_token=trout&extra_param=steve']
          when "json"
            [200, {}, '{"expires_in":600,"access_token":"salmon","refresh_token":"<PASSWORD>","extra_param":"steve"}']
          when "from_facebook"
            [200, {}, 'expires=600&access_token=salmon&refresh_token=trout&extra_param=steve']
          end
        end
{'fraction_non_alphanumeric': 0.16118200134318333, 'fraction_numerical': 0.026863666890530557, 'mean_word_length': 3.1620111731843576, 'pattern_counts': {'":': 8, '<': 4, '<?xml version=': 0, '>': 6, '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': '3733834', 'n_tokens_mistral': 511, 'n_tokens_neox': 484, 'n_words': 76}