upgrade to rails 3, make item tests pass

This commit is contained in:
Emi Matchu 2010-10-03 19:49:33 -04:00
parent 3c473bee2c
commit 531aac6523
62 changed files with 162 additions and 178 deletions

14
Gemfile
View file

@ -1,22 +1,22 @@
source 'http://rubygems.org' source 'http://rubygems.org'
gem 'rails', '3.0.0.beta4' gem 'rails', '3.0.0'
gem 'sqlite3-ruby', :require => 'sqlite3' gem 'sqlite3-ruby', :require => 'sqlite3'
gem 'haml', '>= 3.0.0' gem 'haml', '~> 3.0.18'
gem 'will_paginate', :git => 'http://github.com/mislav/will_paginate.git', :branch => 'rails3' gem 'will_paginate', '~> 3.0.pre2'
gem 'rdiscount' gem 'rdiscount', '~> 1.6.5'
gem 'compass', '>= 0.10.1' gem 'compass', '~> 0.10.1'
group :development do group :development do
gem 'mysql' gem 'mysql'
end end
group :test do group :test do
gem 'rspec-rails', '>= 2.0.0.beta.8' gem 'rspec-rails', '~> 2.0.0.beta.22'
gem 'factory_girl_rails' gem 'factory_girl_rails', '~> 1.0'
end end

View file

@ -1,131 +1,103 @@
--- GEM
hash: a126f60340d5ff8894e44c49aca44bfd89843564 remote: http://rubygems.org/
sources: specs:
- Git: abstract (1.0.0)
git: http://github.com/mislav/will_paginate.git actionmailer (3.0.0)
branch: rails3 actionpack (= 3.0.0)
uri: http://github.com/mislav/will_paginate.git mail (~> 2.2.5)
ref: 60aa1c7b2ef03ee7c7a5ed657efb479a69f7d128 actionpack (3.0.0)
- Rubygems: activemodel (= 3.0.0)
uri: http://rubygems.org activesupport (= 3.0.0)
specs: builder (~> 2.1.2)
- rake: erubis (~> 2.6.6)
version: 0.8.7 i18n (~> 0.4.1)
- abstract: rack (~> 1.2.1)
version: 1.0.0 rack-mount (~> 0.6.12)
- activesupport: rack-test (~> 0.5.4)
version: 3.0.0.beta4 tzinfo (~> 0.3.23)
- builder: activemodel (3.0.0)
version: 2.1.2 activesupport (= 3.0.0)
- i18n: builder (~> 2.1.2)
version: 0.4.1 i18n (~> 0.4.1)
- activemodel: activerecord (3.0.0)
version: 3.0.0.beta4 activemodel (= 3.0.0)
- erubis: activesupport (= 3.0.0)
version: 2.6.6 arel (~> 1.0.0)
- rack: tzinfo (~> 0.3.23)
version: 1.1.0 activeresource (3.0.0)
- rack-mount: activemodel (= 3.0.0)
version: 0.6.6 activesupport (= 3.0.0)
- rack-test: activesupport (3.0.0)
version: 0.5.4 arel (1.0.1)
- tzinfo: activesupport (~> 3.0.0)
version: 0.3.22 builder (2.1.2)
- actionpack: compass (0.10.5)
version: 3.0.0.beta4 haml (>= 3.0.4)
- mime-types: diff-lcs (1.1.2)
version: "1.16" erubis (2.6.6)
- polyglot: abstract (>= 1.0.0)
version: 0.3.1 factory_girl (1.3.2)
- treetop: factory_girl_rails (1.0)
version: 1.4.8 factory_girl (~> 1.3)
- mail: rails (>= 3.0.0.beta4)
version: 2.2.5 haml (3.0.21)
- actionmailer: i18n (0.4.1)
version: 3.0.0.beta4 mail (2.2.6.1)
- arel: activesupport (>= 2.3.6)
version: 0.4.0 mime-types
- activerecord: treetop (>= 1.4.5)
version: 3.0.0.beta4 mime-types (1.16)
- activeresource: mysql (2.8.1)
version: 3.0.0.beta4 polyglot (0.3.1)
- bundler: rack (1.2.1)
version: 0.9.26 rack-mount (0.6.13)
- haml: rack (>= 1.0.0)
version: 3.0.17 rack-test (0.5.6)
- compass: rack (>= 1.0)
version: 0.10.4 rails (3.0.0)
- diff-lcs: actionmailer (= 3.0.0)
version: 1.1.2 actionpack (= 3.0.0)
- factory_girl: activerecord (= 3.0.0)
version: 1.3.1 activeresource (= 3.0.0)
- thor: activesupport (= 3.0.0)
version: 0.13.7 bundler (~> 1.0.0)
- railties: railties (= 3.0.0)
version: 3.0.0.beta4 railties (3.0.0)
- rails: actionpack (= 3.0.0)
version: 3.0.0.beta4 activesupport (= 3.0.0)
- factory_girl_rails: rake (>= 0.8.4)
version: "1.0" thor (~> 0.14.0)
- mysql: rake (0.8.7)
version: 2.8.1 rdiscount (1.6.5)
- nokogiri: rspec (2.0.0.beta.22)
version: 1.4.3.1 rspec-core (= 2.0.0.beta.22)
- rdiscount: rspec-expectations (= 2.0.0.beta.22)
version: 1.6.5 rspec-mocks (= 2.0.0.beta.22)
- rspec-core: rspec-core (2.0.0.beta.22)
version: 2.0.0.beta.16 rspec-expectations (2.0.0.beta.22)
- rspec-expectations: diff-lcs (>= 1.1.2)
version: 2.0.0.beta.16 rspec-mocks (2.0.0.beta.22)
- rspec-mocks: rspec-core (= 2.0.0.beta.22)
version: 2.0.0.beta.16 rspec-expectations (= 2.0.0.beta.22)
- rspec: rspec-rails (2.0.0.beta.22)
version: 2.0.0.beta.16 rspec (= 2.0.0.beta.22)
- webrat: sqlite3-ruby (1.3.1)
version: 0.7.1 thor (0.14.2)
- rspec-rails: treetop (1.4.8)
version: 2.0.0.beta.16 polyglot (>= 0.3.1)
- sqlite3-ruby: tzinfo (0.3.23)
version: 1.3.1 will_paginate (3.0.pre2)
- will_paginate:
version: 3.0.pre PLATFORMS
source: 0 ruby
dependencies:
rails: DEPENDENCIES
version: = 3.0.0.beta4 compass (~> 0.10.1)
group: factory_girl_rails (~> 1.0)
- :default haml (~> 3.0.18)
sqlite3-ruby: mysql
version: ">= 0" rails (= 3.0.0)
group: rdiscount (~> 1.6.5)
- :default rspec-rails (~> 2.0.0.beta.22)
require: sqlite3-ruby
- sqlite3 will_paginate (~> 3.0.pre2)
haml:
version: ">= 3.0.0"
group:
- :default
will_paginate:
version: ">= 0"
group:
- :default
rdiscount:
version: ">= 0"
group:
- :default
compass:
version: ">= 0.10.1"
group:
- :default
mysql:
version: ">= 0"
group:
- :development
rspec-rails:
version: ">= 2.0.0.beta.8"
group:
- :test
factory_girl_rails:
version: ">= 0"
group:
- :test

View file

@ -7,4 +7,4 @@ require 'rake'
require 'rake/testtask' require 'rake/testtask'
require 'rake/rdoctask' require 'rake/rdoctask'
Rails::Application.load_tasks OpenneoImpressItems::Application.load_tasks

View file

@ -16,6 +16,8 @@ OpenneoImpressItems::Application.configure do
# Don't care if the mailer can't send # Don't care if the mailer can't send
config.action_mailer.raise_delivery_errors = false config.action_mailer.raise_delivery_errors = false
config.active_support.deprecation = :log
end end
RemoteImpressHost = 'beta.impress.openneo.net' RemoteImpressHost = 'beta.impress.openneo.net'

View file

@ -39,6 +39,8 @@ OpenneoImpressItems::Application.configure do
# Enable threaded mode # Enable threaded mode
# config.threadsafe! # config.threadsafe!
config.active_support.deprecation = :log
end end
RemoteImpressHost = 'impress.openneo.net' RemoteImpressHost = 'impress.openneo.net'

View file

@ -26,6 +26,8 @@ OpenneoImpressItems::Application.configure do
# This is necessary if your schema can't be completely dumped by the schema dumper, # This is necessary if your schema can't be completely dumped by the schema dumper,
# like if you have constraints or database-specific column types # like if you have constraints or database-specific column types
# config.active_record.schema_format = :sql # config.active_record.schema_format = :sql
config.active_support.deprecation = :stderr
end end
RemoteImpressHost = 'impress.openneo.net' RemoteImpressHost = 'impress.openneo.net'

View file

@ -1,5 +1,5 @@
require 'compass' require 'compass'
rails_root = (defined?(Rails) ? Rails.root : RAILS_ROOT).to_s rails_root = Rails.root.to_s
Compass.add_project_configuration(File.join(rails_root, "config", "compass.rb")) Compass.add_project_configuration(Rails.root.join(rails_root, "config", "compass.rb"))
Compass.configure_sass_plugin! Compass.configure_sass_plugin!
Compass.handle_configuration_change! Compass.handle_configuration_change!

View file

@ -4,4 +4,4 @@
# If you change this key, all old signed cookies will become invalid! # If you change this key, all old signed cookies will become invalid!
# Make sure the secret is at least 30 characters and all random, # Make sure the secret is at least 30 characters and all random,
# no regular words or you'll be exposed to dictionary attacks. # no regular words or you'll be exposed to dictionary attacks.
Rails.application.config.cookie_secret = '03a62dcef9d831912de9f0c1815e6226981b880195184893803ae0d3c4e696c52102f2deb611ccbeb2c7b90bd9d30a78c7fad62fec908a20d048449e6d10b7f9' Rails.application.config.secret_token = '03a62dcef9d831912de9f0c1815e6226981b880195184893803ae0d3c4e696c52102f2deb611ccbeb2c7b90bd9d30a78c7fad62fec908a20d048449e6d10b7f9'

View file

@ -2,87 +2,87 @@
body.bp { body.bp {
text-align: center; text-align: center;
} }
/* line 48, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 48, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
* html body.bp legend { * html body.bp legend {
margin: 0px -8px 16px 0; margin: 0px -8px 16px 0;
padding: 0; padding: 0;
} }
/* line 52, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 52, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
html > body.bp p code { html > body.bp p code {
*white-space: normal; *white-space: normal;
} }
/* line 67, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 67, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp .container { body.bp .container {
text-align: left; text-align: left;
} }
/* line 69, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 69, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp sup { body.bp sup {
vertical-align: text-top; vertical-align: text-top;
} }
/* line 71, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 71, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp sub { body.bp sub {
vertical-align: text-bottom; vertical-align: text-bottom;
} }
/* line 73, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 73, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp hr { body.bp hr {
margin: -8px auto 11px; margin: -8px auto 11px;
} }
/* line 75, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 75, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp img { body.bp img {
-ms-interpolation-mode: bicubic; -ms-interpolation-mode: bicubic;
} }
/* line 77, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 77, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp fieldset { body.bp fieldset {
padding-top: 0; padding-top: 0;
} }
/* line 79, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 79, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp textarea { body.bp textarea {
overflow: auto; overflow: auto;
} }
/* line 82, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 82, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp input.text { body.bp input.text {
margin: 0.5em 0; margin: 0.5em 0;
background-color: white; background-color: white;
border: 1px solid #bbbbbb; border: 1px solid #bbbbbb;
} }
/* line 86, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 86, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp input.text:focus { body.bp input.text:focus {
border: 1px solid #666666; border: 1px solid #666666;
} }
/* line 88, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 88, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp input.title { body.bp input.title {
margin: 0.5em 0; margin: 0.5em 0;
background-color: white; background-color: white;
border: 1px solid #bbbbbb; border: 1px solid #bbbbbb;
} }
/* line 92, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 92, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp input.title:focus { body.bp input.title:focus {
border: 1px solid #666666; border: 1px solid #666666;
} }
/* line 94, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 94, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp input.checkbox { body.bp input.checkbox {
position: relative; position: relative;
top: 0.25em; top: 0.25em;
} }
/* line 97, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 97, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp input.radio { body.bp input.radio {
position: relative; position: relative;
top: 0.25em; top: 0.25em;
} }
/* line 100, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 100, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp input.button { body.bp input.button {
position: relative; position: relative;
top: 0.25em; top: 0.25em;
} }
/* line 103, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 103, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp textarea { body.bp textarea {
margin: 0.5em 0; margin: 0.5em 0;
} }
/* line 105, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 105, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp select { body.bp select {
margin: 0.5em 0; margin: 0.5em 0;
} }
/* line 107, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_ie.scss */ /* line 107, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_ie.scss */
body.bp button { body.bp button {
position: relative; position: relative;
top: 0.25em; top: 0.25em;

View file

@ -6,11 +6,11 @@ body.bp {
background: none; background: none;
font-size: 10pt; font-size: 10pt;
} }
/* line 52, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 52, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp .container { body.bp .container {
background: none; background: none;
} }
/* line 54, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 54, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp hr { body.bp hr {
background: #cccccc; background: #cccccc;
color: #cccccc; color: #cccccc;
@ -20,54 +20,54 @@ body.bp hr {
padding: 0; padding: 0;
border: none; border: none;
} }
/* line 62, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 62, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp hr.space { body.bp hr.space {
background: white; background: white;
color: white; color: white;
} }
/* line 65, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 65, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp h1, body.bp h2, body.bp h3, body.bp h4, body.bp h5, body.bp h6 { body.bp h1, body.bp h2, body.bp h3, body.bp h4, body.bp h5, body.bp h6 {
font-family: "Helvetica Neue", Arial, Helvetica, sans-serif; font-family: "Helvetica Neue", Arial, Helvetica, sans-serif;
} }
/* line 67, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 67, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp code { body.bp code {
font-size: 0.9em; font-size: 0.9em;
font-family: "andale mono", "lucida console", monospace; font-family: "andale mono", "lucida console", monospace;
} }
/* line 72, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 72, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp a img { body.bp a img {
border: none; border: none;
} }
/* line 75, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 75, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp a:link, body.bp a:visited { body.bp a:link, body.bp a:visited {
background: transparent; background: transparent;
font-weight: 700; font-weight: 700;
text-decoration: underline; text-decoration: underline;
} }
/* line 79, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 79, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp p img.top { body.bp p img.top {
margin-top: 0; margin-top: 0;
} }
/* line 81, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 81, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp blockquote { body.bp blockquote {
margin: 1.5em; margin: 1.5em;
padding: 1em; padding: 1em;
font-style: italic; font-style: italic;
font-size: 0.9em; font-size: 0.9em;
} }
/* line 86, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 86, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp .small { body.bp .small {
font-size: 0.9em; font-size: 0.9em;
} }
/* line 88, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 88, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp .large { body.bp .large {
font-size: 1.1em; font-size: 1.1em;
} }
/* line 90, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 90, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp .quiet { body.bp .quiet {
color: #999999; color: #999999;
} }
/* line 92, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.4/frameworks/blueprint/stylesheets/blueprint/_print.scss */ /* line 92, ../../../../../.rvm/gems/ruby-1.9.2-preview3/gems/compass-0.10.5/frameworks/blueprint/stylesheets/blueprint/_print.scss */
body.bp .hide { body.bp .hide {
display: none; display: none;
} }

View file

@ -24,6 +24,8 @@ describe Item do
end end
specify "should have many swf_assets through parent_swf_asset_relationships" do specify "should have many swf_assets through parent_swf_asset_relationships" do
SwfAsset.delete_all
ParentSwfAssetRelationship.delete_all
3.times do |n| 3.times do |n|
swf_asset = Factory.create :swf_asset, :id => n, :url => "http://images.neopets.com/#{n}.swf", :type => 'object' swf_asset = Factory.create :swf_asset, :id => n, :url => "http://images.neopets.com/#{n}.swf", :type => 'object'
ParentSwfAssetRelationship.create :swf_asset => swf_asset, :item => @item, :swf_asset_type => 'object' ParentSwfAssetRelationship.create :swf_asset => swf_asset, :item => @item, :swf_asset_type => 'object'
@ -39,6 +41,10 @@ describe Item do
end end
context "class" do context "class" do
before :each do
Item.delete_all # don't want search returning results from previous tests
end
specify "should search name for word" do specify "should search name for word" do
query_should 'blue', query_should 'blue',
:return => [ :return => [
@ -160,10 +166,10 @@ describe Item do
Factory.create :item, :name => 'not mall', :rarity_index => 400 Factory.create :item, :name => 'not mall', :rarity_index => 400
Factory.create :item, :name => 'also not mall', :rarity_index => 101 Factory.create :item, :name => 'also not mall', :rarity_index => 101
Item.search('is:nc').map(&:name).should == ['mall', 'also mall', 'only mall'] Item.search('is:nc').map(&:name).should == ['mall', 'also mall', 'only mall']
Item.search('!is:nc').map(&:name).should == ['not mall', 'also not mall'] Item.search('-is:nc').map(&:name).should == ['not mall', 'also not mall']
end end
specify "is:(anything but 'nc') should throw ArgumentError" do specify "is:[not 'nc' or 'pb'] should throw ArgumentError" do
lambda { Item.search('is:nc') }.should_not raise_error(ArgumentError) lambda { Item.search('is:nc') }.should_not raise_error(ArgumentError)
lambda { Item.search('is:awesome') }.should raise_error(ArgumentError) lambda { Item.search('is:awesome') }.should raise_error(ArgumentError)
end end

View file

@ -23,7 +23,7 @@ Rspec.configure do |config|
# config.use_transactional_examples = false # config.use_transactional_examples = false
def query_should(query, sets) def query_should(query, sets)
sets = sets.each { |k,v| sets[k] = v.map { |x| x.is_a?(Array) ? x : [x, ''] } } sets.each { |k,v| sets[k] = v.map { |x| x.is_a?(Array) ? x : [x, ''] } }
all_sets = sets[:return] + sets[:not_return] all_sets = sets[:return] + sets[:not_return]
all_sets.each { |s| Factory.create :item, :name => s[0], :description => s[1]} all_sets.each { |s| Factory.create :item, :name => s[0], :description => s[1]}
returned_sets = Item.search(query).all.map { |i| [i.name, i.description] }.sort returned_sets = Item.search(query).all.map { |i| [i.name, i.description] }.sort

View file

@ -11,5 +11,5 @@ Factory.define :item do |i|
i.weight_lbs 0 i.weight_lbs 0
i.species_support_ids '' i.species_support_ids ''
i.sold_in_mall false i.sold_in_mall false
i.last_spidered 0 i.last_spidered Time.now
end end

Binary file not shown.

BIN
vendor/cache/actionmailer-3.0.0.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/actionpack-3.0.0.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/activemodel-3.0.0.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/activerecord-3.0.0.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/activeresource-3.0.0.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/activesupport-3.0.0.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/arel-1.0.1.gem vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/factory_girl-1.3.2.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/haml-3.0.21.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/mail-2.2.6.1.gem vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/rack-1.2.1.gem vendored Normal file

Binary file not shown.

BIN
vendor/cache/rack-mount-0.6.13.gem vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/rack-test-0.5.6.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/railties-3.0.0.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/rspec-2.0.0.beta.22.gem vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/thor-0.14.2.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/tzinfo-0.3.23.gem vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
vendor/cache/will_paginate-3.0.pre2.gem vendored Normal file

Binary file not shown.