This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jim@The-Ocean-2 /Users/jim/codez/Blake/blake-admin ruby-2.1.2 develop | |
⚡ bundle (02-12 10:58) | |
The git source `git://github.com/blake-education/winnow.git` uses the `git` protocol, which transmits data without encryption. Disable this warning with `bundle config git.allow_insecure true`, or switch to the `https` protocol to keep your data secure. | |
The git source `git://github.com/binarylogic/authlogic.git` uses the `git` protocol, which transmits data without encryption. Disable this warning with `bundle config git.allow_insecure true`, or switch to the `https` protocol to keep your data secure. | |
The git source `git://github.com/kovyrin/db-charmer.git` uses the `git` protocol, which transmits data without encryption. Disable this war |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jim@The-Ocean /Users/jim/codez/Blake/wf-teacher ruby-2.1.2 develop | |
⚡ rails c (09-06 14:58) | |
bundle exec rails c | |
WARNING: Nokogiri was built against LibXML version 2.9.2, but has dynamically loaded 2.9.4 | |
/Users/jim/codez/Blake/wf-teacher/vendor/bundle/gems/mysql2-0.3.21/lib/mysql2/client.rb:70:in `connect': Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) (Mysql2::Error) | |
from /Users/jim/codez/Blake/wf-teacher/vendor/bundle/gems/mysql2-0.3.21/lib/mysql2/client.rb:70:in `initialize' | |
from /Users/jim/codez/Blake/wf-teacher/vendor/bundle/gems/activerecord-4.0.13/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in `new' | |
from /Users/jim/codez/Blake/wf-teacher/vendor/bundle/gems/activerecord-4.0.13/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in `mysql2_connection' | |
from /Users |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FactoryGirl.define do | |
factory :currency do | |
name Forgery::Currency.description | |
sequence(:short_name) { |sn| "#{Forgery::Currency.code}#{sn}" } | |
symbol '$' | |
end | |
factory :price do | |
full_price { 6000 } | |
discount_price { 3000 } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'mail' | |
class EmailValidator < ActiveModel::EachValidator | |
attr_reader :record, :attribute, :value, :email, :tree | |
def validate_each(record, attribute, value) | |
@record, @attribute, @value = record, attribute, value | |
@email = Mail::Address.new(value) | |
@tree = email.__send__(:tree) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/test/integration/rememberable_test.rb b/test/integration/rememberable_test.rb | |
index 14e66fb..295fab0 100644 | |
--- a/test/integration/rememberable_test.rb | |
+++ b/test/integration/rememberable_test.rb | |
@@ -54,6 +54,7 @@ class RememberMeTest < ActionController::IntegrationTest | |
test 'remember the user before sign in' do | |
user = create_user_and_remember | |
get users_path | |
assert_response :success |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# config/environment.rb | |
# ... | |
Dir[Rails.root + 'lib/monkey_patches/**/*.rb'].each { |file| require file } | |
# ... |