test/test_helper.rb in activevalidators-2.0.2 vs test/test_helper.rb in activevalidators-2.1.0

- old
+ new

@@ -1,27 +1,21 @@ -require 'rubygems' +gem 'minitest' +require 'minitest/autorun' +require 'minitest/mock' # silence warnings old_w, $-w = $-w, false -require 'minitest/spec' -require 'minitest/mock' -require 'minitest/autorun' +require 'activevalidators' # unsilence warnings $-w = old_w -require 'activevalidators' - -%w(models).each do |directory| - Dir["#{File.dirname(__FILE__)}/#{directory}/*.rb"].each {|f| require f} -end - class TestRecord include ActiveModel::Validations attr_accessor :ip, :url, :slug, :responder, :global_condition, :local_condition, :phone, :email, :card, :password, :twitter_username, - :postal_code, :carrier, :tracking_number, :start_date, :end_date + :postal_code, :carrier, :tracking_number, :start_date, :end_date, :siren def initialize(attrs = {}) attrs.each_pair { |k,v| send("#{k}=", v) } end end