<commit_before>require 'spec_helper'

describe Spree::Payment do

  context 'validation' do
    it { should have_valid_factory(:payment) }
  end

  let(:order) { mock_model(Spree::Order, :update! => nil, :payments => []) }
  let(:gateway) { Spree::Gateway::Bogus.new(:environment => 'test', :active => true) }
  let(:card) { Factory(:creditcard) }

  before(:each) do<commit_msg>Don't use protection when creating a gateway in Payment spec<commit_after>require 'spec_helper'

describe Spree::Payment do

  context 'validation' do
    it { should have_valid_factory(:payment) }
  end

  let(:order) { mock_model(Spree::Order, :update! => nil, :payments => []) }
  let(:gateway) { Spree::Gateway::Bogus.new({:environment => 'test', :active => true}, :without_protection => true) }
  let(:card) { Factory(:creditcard) }

  before(:each) do
{'fraction_non_alphanumeric': 0.16626794258373206, 'fraction_numerical': 0.0, 'mean_word_length': 5.3893129770992365, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 12, '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': '6590775', 'n_tokens_mistral': 282, 'n_tokens_neox': 270, 'n_words': 62}