Permalink
Browse files

Upgrading. Also, fuck you, FactoryGirl.

  • Loading branch information...
1 parent 787e9a0 commit 00fab75eee84bc6223f6a38c32029fc9bc3068f8 @tekniklr committed Apr 1, 2012
View
@@ -50,63 +50,64 @@ GEM
actionmailer (>= 3.0.4)
execjs (1.3.0)
multi_json (~> 1.0)
- factory_girl (2.6.0)
- activesupport (>= 2.3.9)
- factory_girl_rails (1.7.0)
- factory_girl (~> 2.6.0)
+ factory_girl (3.0.0)
+ activesupport (>= 3.0.0)
+ factory_girl_rails (3.0.0)
+ factory_girl (~> 3.0.0)
railties (>= 3.0.0)
faraday (0.7.6)
addressable (~> 2.2)
multipart-post (~> 1.1)
rack (~> 1.1)
haml (3.1.4)
hashie (1.2.0)
- heroku (2.20.1)
+ heroku (2.23.0)
launchy (>= 0.3.2)
+ netrc (~> 0.7.1)
rest-client (~> 1.6.1)
rubyzip
- term-ansicolor (~> 1.0.5)
hike (1.2.1)
- hirb (0.6.0)
+ hirb (0.6.2)
i18n (0.6.0)
journey (1.0.3)
- jquery-rails (2.0.0)
- railties (>= 3.2.0.beta, < 5.0)
+ jquery-rails (2.0.1)
+ railties (>= 3.2.0, < 5.0)
thor (~> 0.14)
- json (1.6.5)
- launchy (2.0.5)
+ json (1.6.6)
+ launchy (2.1.0)
addressable (~> 2.2.6)
looksee (1.0.3)
- mail (2.4.1)
+ mail (2.4.4)
i18n (>= 0.4.0)
mime-types (~> 1.16)
treetop (~> 1.4.8)
mime-types (1.17.2)
- minitest (2.11.2)
- multi_json (1.1.0)
+ minitest (2.11.4)
+ multi_json (1.2.0)
multipart-post (1.1.5)
+ netrc (0.7.1)
oauth (0.4.5)
oauth2 (0.5.2)
faraday (~> 0.7)
multi_json (~> 1.0)
- omniauth (1.0.2)
+ omniauth (1.0.3)
hashie (~> 1.2)
rack
omniauth-facebook (1.2.0)
omniauth-oauth2 (~> 1.0.0)
- omniauth-oauth (1.0.0)
+ omniauth-oauth (1.0.1)
oauth
omniauth (~> 1.0)
omniauth-oauth2 (1.0.0)
oauth2 (~> 0.5.0)
omniauth (~> 1.0)
- omniauth-twitter (0.0.8)
+ omniauth-twitter (0.0.9)
omniauth-oauth (~> 1.0)
- orm_adapter (0.0.6)
+ orm_adapter (0.0.7)
pg (0.13.2)
polyglot (0.3.3)
rack (1.4.1)
- rack-cache (1.1)
+ rack-cache (1.2)
rack (>= 0.4)
rack-ssl (1.3.2)
rack
@@ -135,28 +136,31 @@ GEM
mime-types (>= 1.16)
rubyzip (0.9.6.1)
sass (3.1.15)
- sass-rails (3.2.4)
+ sass-rails (3.2.5)
railties (~> 3.2.0)
sass (>= 3.1.10)
tilt (~> 1.3)
sequel (3.20.0)
- shoulda (2.11.3)
+ shoulda (3.0.1)
+ shoulda-context (~> 1.0.0)
+ shoulda-matchers (~> 1.0.0)
+ shoulda-context (1.0.0)
+ shoulda-matchers (1.0.0)
sinatra (1.0)
rack (>= 1.0)
sprockets (2.1.2)
hike (~> 1.2)
rack (~> 1.0)
- tilt (~> 1.1, != 1.3.0)
+ tilt (!= 1.3.0, ~> 1.1)
sqlite3 (1.3.5)
sqlite3-ruby (1.3.3)
sqlite3 (>= 1.3.3)
taps (0.3.23)
rack (>= 1.0.1)
- rest-client (>= 1.4.0, < 1.7.0)
+ rest-client (< 1.7.0, >= 1.4.0)
sequel (~> 3.20.0)
sinatra (~> 1.0.0)
sqlite3-ruby (~> 1.2)
- term-ansicolor (1.0.7)
thin (1.3.1)
daemons (>= 1.0.9)
eventmachine (>= 0.12.6)
@@ -166,9 +170,9 @@ GEM
treetop (1.4.10)
polyglot
polyglot (>= 0.3.1)
- turn (0.9.3)
+ turn (0.9.4)
ansi
- tzinfo (0.3.31)
+ tzinfo (0.3.32)
uglifier (1.0.4)
execjs (>= 0.3.0)
multi_json (>= 1.0.2)
View
@@ -1,18 +1,22 @@
-Factory.define :user do |u|
- u.sequence(:name) {|n| "User: #{n}"}
- u.provider 'twitter'
- u.uid '12345'
- u.handle 'tekniklr'
-end
+FactoryGirl.define do
+
+ factory :user do |u|
+ u.sequence(:name) {|n| "User: #{n}"}
+ u.provider 'twitter'
+ u.uid '12345'
+ u.handle 'tekniklr'
+ end
-Factory.define :blurb do |f|
- f.sequence(:name) {|n| "Blurb #{n}"}
- f.content "stuff, stuff, and more stuff"
-end
+ factory :blurb do |f|
+ f.sequence(:name) {|n| "Blurb #{n}"}
+ f.content "stuff, stuff, and more stuff"
+ end
-Factory.define :contact do |f|
- f.sequence(:name) {|n| "Contact #{n}"}
- f.email "example@example.com"
- f.phone "(123)456-7890"
- f.content "stuff, stuff, and more stuff"
+ factory :contact do |f|
+ f.sequence(:name) {|n| "Contact #{n}"}
+ f.email "example@example.com"
+ f.phone "(123)456-7890"
+ f.content "stuff, stuff, and more stuff"
+ end
+
end
@@ -2,13 +2,13 @@
class BlurbsControllerTest < ActionController::TestCase
setup do
- @blurb = Factory.create(:blurb)
+ @blurb = FactoryGirl.create(:blurb)
end
context "when logged in" do
setup do
- @user = Factory.create(:user)
+ @user = FactoryGirl.create(:user)
end
should "get index" do
@@ -2,7 +2,7 @@
class ContactsControllerTest < ActionController::TestCase
setup do
- @contact = Factory.build(:contact)
+ @contact = FactoryGirl.build(:contact)
end
test "should get new" do
@@ -3,7 +3,7 @@
class BlurbTest < ActiveSupport::TestCase
def setup
- @blurb = Factory.build(:blurb)
+ @blurb = FactoryGirl.build(:blurb)
end
should "validate presence of name" do
@@ -17,8 +17,8 @@ def setup
end
should "validate uniqueness of name" do
- blurb1 = Factory.create(:blurb, :name => 'some name')
- blurb2 = Factory.build(:blurb, :name => 'some name')
+ blurb1 = FactoryGirl.create(:blurb, :name => 'some name')
+ blurb2 = FactoryGirl.build(:blurb, :name => 'some name')
assert !blurb2.valid?
end
@@ -3,7 +3,7 @@
class ContactTest < ActiveSupport::TestCase
def setup
- @contact = Factory.build(:contact)
+ @contact = FactoryGirl.build(:contact)
end
should "validate presence of name" do

0 comments on commit 00fab75

Please sign in to comment.