ordering a product

Start with a pre-canned application

ruby -rubygems /home/rubys/git/rails/bin/rails new corrupt
      create  
      create  README
      create  Rakefile
      create  config.ru
      create  .gitignore
      create  Gemfile
      create  app
      create  app/controllers/application_controller.rb
      create  app/helpers/application_helper.rb
      create  app/mailers
      create  app/models
      create  app/views/layouts/application.html.erb
      create  config
      create  config/routes.rb
      create  config/application.rb
      create  config/environment.rb
      create  config/environments
      create  config/environments/development.rb
      create  config/environments/production.rb
      create  config/environments/test.rb
      create  config/initializers
      create  config/initializers/backtrace_silencers.rb
      create  config/initializers/inflections.rb
      create  config/initializers/mime_types.rb
      create  config/initializers/secret_token.rb
      create  config/initializers/session_store.rb
      create  config/locales
      create  config/locales/en.yml
      create  config/boot.rb
      create  config/database.yml
      create  db
      create  db/seeds.rb
      create  doc
      create  doc/README_FOR_APP
      create  lib
      create  lib/tasks
      create  lib/tasks/.gitkeep
      create  log
      create  log/server.log
      create  log/production.log
      create  log/development.log
      create  log/test.log
      create  public
      create  public/404.html
      create  public/422.html
      create  public/500.html
      create  public/favicon.ico
      create  public/index.html
      create  public/robots.txt
      create  public/images
      create  public/images/rails.png
      create  public/stylesheets
      create  public/stylesheets/.gitkeep
      create  public/javascripts
      create  public/javascripts/prototype.js
      create  public/javascripts/rails.js
      create  public/javascripts/application.js
      create  script
      create  script/rails
      create  test
      create  test/fixtures
      create  test/functional
      create  test/integration
      create  test/performance/browsing_test.rb
      create  test/test_helper.rb
      create  test/unit
      create  tmp
      create  tmp/sessions
      create  tmp/sockets
      create  tmp/cache
      create  tmp/pids
      create  vendor/plugins
      create  vendor/plugins/.gitkeep
bundle install
Using rake (0.8.7) 
Using abstract (1.0.0) 
Using activesupport (3.1.0.beta) from source at /home/rubys/git/rails 
Using builder (3.0.0) 
Using i18n (0.5.0) 
Using activemodel (3.1.0.beta) from source at /home/rubys/git/rails 
Using erubis (2.6.6) 
Using rack (1.2.1) from source at /home/rubys/git/rack 
Using rack-cache (0.5.3) 
Using rack-mount (0.6.13) 
Using rack-test (0.5.6) 
Using tzinfo (0.3.23) 
Using actionpack (3.1.0.beta) from source at /home/rubys/git/rails 
Using mime-types (1.16) 
Using polyglot (0.3.1) 
Using treetop (1.4.9) 
Using mail (2.2.12) 
Using actionmailer (3.1.0.beta) from source at /home/rubys/git/rails 
Using arel (2.0.7.beta.20101201093009) from source at /home/rubys/git/arel 
Using activerecord (3.1.0.beta) from source at /home/rubys/git/rails 
Using activeresource (3.1.0.beta) from source at /home/rubys/git/rails 
Using bundler (1.0.7) 
Using thor (0.14.6) 
Using railties (3.1.0.beta) from source at /home/rubys/git/rails 
Using rails (3.1.0.beta) from source at /home/rubys/git/rails 
Using sqlite3-ruby (1.3.2) 
Your bundle is complete! Use `bundle show [gemname]` to see where a bundled gem is installed.
cp -rpv ~/tmp/pre-corruption/* .
`/home/rubys/tmp/pre-corruption/Gemfile' -> `./Gemfile'
`/home/rubys/tmp/pre-corruption/Gemfile.lock' -> `./Gemfile.lock'
`/home/rubys/tmp/pre-corruption/README' -> `./README'
`/home/rubys/tmp/pre-corruption/Rakefile' -> `./Rakefile'
`/home/rubys/tmp/pre-corruption/app/models/line_item.rb' -> `./app/models/line_item.rb'
`/home/rubys/tmp/pre-corruption/app/models/user.rb' -> `./app/models/user.rb'
`/home/rubys/tmp/pre-corruption/app/models/cart.rb' -> `./app/models/cart.rb'
`/home/rubys/tmp/pre-corruption/app/models/product.rb' -> `./app/models/product.rb'
`/home/rubys/tmp/pre-corruption/app/models/order.rb' -> `./app/models/order.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/orders_helper.rb' -> `./app/helpers/orders_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/sessions_helper.rb' -> `./app/helpers/sessions_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/carts_helper.rb' -> `./app/helpers/carts_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/application_helper.rb' -> `./app/helpers/application_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/store_helper.rb' -> `./app/helpers/store_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/products_helper.rb' -> `./app/helpers/products_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/users_helper.rb' -> `./app/helpers/users_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/admin_helper.rb' -> `./app/helpers/admin_helper.rb'
`/home/rubys/tmp/pre-corruption/app/helpers/line_items_helper.rb' -> `./app/helpers/line_items_helper.rb'
`/home/rubys/tmp/pre-corruption/app/views/store' -> `./app/views/store'
`/home/rubys/tmp/pre-corruption/app/views/store/index.html.erb' -> `./app/views/store/index.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/notifier' -> `./app/views/notifier'
`/home/rubys/tmp/pre-corruption/app/views/notifier/order_received.text.erb' -> `./app/views/notifier/order_received.text.erb'
`/home/rubys/tmp/pre-corruption/app/views/notifier/order_shipped.html.erb' -> `./app/views/notifier/order_shipped.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/notifier/order_shipped.text.erb' -> `./app/views/notifier/order_shipped.text.erb'
`/home/rubys/tmp/pre-corruption/app/views/admin' -> `./app/views/admin'
`/home/rubys/tmp/pre-corruption/app/views/admin/index.html.erb' -> `./app/views/admin/index.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/layouts/application.html.erb' -> `./app/views/layouts/application.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/products' -> `./app/views/products'
`/home/rubys/tmp/pre-corruption/app/views/products/who_bought.html.erb' -> `./app/views/products/who_bought.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/products/who_bought.xml.builder' -> `./app/views/products/who_bought.xml.builder'
`/home/rubys/tmp/pre-corruption/app/views/products/who_bought.atom.builder' -> `./app/views/products/who_bought.atom.builder'
`/home/rubys/tmp/pre-corruption/app/views/products/new.html.erb' -> `./app/views/products/new.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/products/show.html.erb' -> `./app/views/products/show.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/products/index.html.erb' -> `./app/views/products/index.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/products/edit.html.erb' -> `./app/views/products/edit.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/products/_form.html.erb' -> `./app/views/products/_form.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/orders' -> `./app/views/orders'
`/home/rubys/tmp/pre-corruption/app/views/orders/new.html.erb' -> `./app/views/orders/new.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/orders/show.html.erb' -> `./app/views/orders/show.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/orders/index.html.erb' -> `./app/views/orders/index.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/orders/edit.html.erb' -> `./app/views/orders/edit.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/orders/_form.html.erb' -> `./app/views/orders/_form.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/carts' -> `./app/views/carts'
`/home/rubys/tmp/pre-corruption/app/views/carts/new.html.erb' -> `./app/views/carts/new.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/carts/show.html.erb' -> `./app/views/carts/show.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/carts/_cart.html.erb' -> `./app/views/carts/_cart.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/carts/index.html.erb' -> `./app/views/carts/index.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/carts/edit.html.erb' -> `./app/views/carts/edit.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/carts/_form.html.erb' -> `./app/views/carts/_form.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/sessions' -> `./app/views/sessions'
`/home/rubys/tmp/pre-corruption/app/views/sessions/destroy.html.erb' -> `./app/views/sessions/destroy.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/sessions/new.html.erb' -> `./app/views/sessions/new.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/sessions/create.html.erb' -> `./app/views/sessions/create.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/users' -> `./app/views/users'
`/home/rubys/tmp/pre-corruption/app/views/users/new.html.erb' -> `./app/views/users/new.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/users/show.html.erb' -> `./app/views/users/show.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/users/index.html.erb' -> `./app/views/users/index.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/users/edit.html.erb' -> `./app/views/users/edit.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/users/_form.html.erb' -> `./app/views/users/_form.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items' -> `./app/views/line_items'
`/home/rubys/tmp/pre-corruption/app/views/line_items/new.html.erb' -> `./app/views/line_items/new.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items/show.html.erb' -> `./app/views/line_items/show.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items/index.html.erb' -> `./app/views/line_items/index.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items/_line_item.text.erb' -> `./app/views/line_items/_line_item.text.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items/edit.html.erb' -> `./app/views/line_items/edit.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items/_line_item.html.erb' -> `./app/views/line_items/_line_item.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items/_form.html.erb' -> `./app/views/line_items/_form.html.erb'
`/home/rubys/tmp/pre-corruption/app/views/line_items/create.js.rjs' -> `./app/views/line_items/create.js.rjs'
`/home/rubys/tmp/pre-corruption/app/mailers/notifier.rb' -> `./app/mailers/notifier.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/application_controller.rb' -> `./app/controllers/application_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/store_controller.rb' -> `./app/controllers/store_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/carts_controller.rb' -> `./app/controllers/carts_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/products_controller.rb' -> `./app/controllers/products_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/users_controller.rb' -> `./app/controllers/users_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/sessions_controller.rb' -> `./app/controllers/sessions_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/orders_controller.rb' -> `./app/controllers/orders_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/admin_controller.rb' -> `./app/controllers/admin_controller.rb'
`/home/rubys/tmp/pre-corruption/app/controllers/line_items_controller.rb' -> `./app/controllers/line_items_controller.rb'
`/home/rubys/tmp/pre-corruption/config/routes.rb' -> `./config/routes.rb'
`/home/rubys/tmp/pre-corruption/config/environments/production.rb' -> `./config/environments/production.rb'
`/home/rubys/tmp/pre-corruption/config/environments/development.rb' -> `./config/environments/development.rb'
`/home/rubys/tmp/pre-corruption/config/environments/test.rb' -> `./config/environments/test.rb'
`/home/rubys/tmp/pre-corruption/config/database.yml' -> `./config/database.yml'
`/home/rubys/tmp/pre-corruption/config/application.rb' -> `./config/application.rb'
`/home/rubys/tmp/pre-corruption/config/environment.rb' -> `./config/environment.rb'
`/home/rubys/tmp/pre-corruption/config/boot.rb' -> `./config/boot.rb'
`/home/rubys/tmp/pre-corruption/config/locales/en.yml' -> `./config/locales/en.yml'
`/home/rubys/tmp/pre-corruption/config/initializers/secret_token.rb' -> `./config/initializers/secret_token.rb'
`/home/rubys/tmp/pre-corruption/config/initializers/inflections.rb' -> `./config/initializers/inflections.rb'
`/home/rubys/tmp/pre-corruption/config/initializers/session_store.rb' -> `./config/initializers/session_store.rb'
`/home/rubys/tmp/pre-corruption/config/initializers/backtrace_silencers.rb' -> `./config/initializers/backtrace_silencers.rb'
`/home/rubys/tmp/pre-corruption/config/initializers/mime_types.rb' -> `./config/initializers/mime_types.rb'
`/home/rubys/tmp/pre-corruption/config.ru' -> `./config.ru'
`/home/rubys/tmp/pre-corruption/db/migrate' -> `./db/migrate'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000009_create_users.rb' -> `./db/migrate/20110211000009_create_users.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000001_create_products.rb' -> `./db/migrate/20110211000001_create_products.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000005_combine_items_in_cart.rb' -> `./db/migrate/20110211000005_combine_items_in_cart.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000007_create_orders.rb' -> `./db/migrate/20110211000007_create_orders.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000002_create_carts.rb' -> `./db/migrate/20110211000002_create_carts.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000006_add_price_to_line_item.rb' -> `./db/migrate/20110211000006_add_price_to_line_item.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000008_add_order_id_to_line_item.rb' -> `./db/migrate/20110211000008_add_order_id_to_line_item.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000003_create_line_items.rb' -> `./db/migrate/20110211000003_create_line_items.rb'
`/home/rubys/tmp/pre-corruption/db/migrate/20110211000004_add_quantity_to_line_item.rb' -> `./db/migrate/20110211000004_add_quantity_to_line_item.rb'
`/home/rubys/tmp/pre-corruption/db/seeds.rb' -> `./db/seeds.rb'
`/home/rubys/tmp/pre-corruption/doc/README_FOR_APP' -> `./doc/README_FOR_APP'
`/home/rubys/tmp/pre-corruption/lib/tasks/.gitkeep' -> `./lib/tasks/.gitkeep'
`/home/rubys/tmp/pre-corruption/public/404.html' -> `./public/404.html'
`/home/rubys/tmp/pre-corruption/public/stylesheets/scaffold.css' -> `./public/stylesheets/scaffold.css'
`/home/rubys/tmp/pre-corruption/public/stylesheets/depot.css' -> `./public/stylesheets/depot.css'
`/home/rubys/tmp/pre-corruption/public/stylesheets/.gitkeep' -> `./public/stylesheets/.gitkeep'
`/home/rubys/tmp/pre-corruption/public/images/rails.png' -> `./public/images/rails.png'
`/home/rubys/tmp/pre-corruption/public/422.html' -> `./public/422.html'
`/home/rubys/tmp/pre-corruption/public/javascripts/prototype.js' -> `./public/javascripts/prototype.js'
`/home/rubys/tmp/pre-corruption/public/javascripts/application.js' -> `./public/javascripts/application.js'
`/home/rubys/tmp/pre-corruption/public/javascripts/rails.js' -> `./public/javascripts/rails.js'
`/home/rubys/tmp/pre-corruption/public/500.html' -> `./public/500.html'
`/home/rubys/tmp/pre-corruption/public/robots.txt' -> `./public/robots.txt'
`/home/rubys/tmp/pre-corruption/public/favicon.ico' -> `./public/favicon.ico'
`/home/rubys/tmp/pre-corruption/script/rails' -> `./script/rails'
`/home/rubys/tmp/pre-corruption/script/load_orders.rb' -> `./script/load_orders.rb'
`/home/rubys/tmp/pre-corruption/test/integration/dsl_user_stories_test.rb' -> `./test/integration/dsl_user_stories_test.rb'
`/home/rubys/tmp/pre-corruption/test/integration/user_stories_test.rb' -> `./test/integration/user_stories_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/user_test.rb' -> `./test/unit/user_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/order_test.rb' -> `./test/unit/order_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/cart_test.rb' -> `./test/unit/cart_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers' -> `./test/unit/helpers'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/users_helper_test.rb' -> `./test/unit/helpers/users_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/line_items_helper_test.rb' -> `./test/unit/helpers/line_items_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/products_helper_test.rb' -> `./test/unit/helpers/products_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/carts_helper_test.rb' -> `./test/unit/helpers/carts_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/orders_helper_test.rb' -> `./test/unit/helpers/orders_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/sessions_helper_test.rb' -> `./test/unit/helpers/sessions_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/store_helper_test.rb' -> `./test/unit/helpers/store_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/helpers/admin_helper_test.rb' -> `./test/unit/helpers/admin_helper_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/product_test.rb' -> `./test/unit/product_test.rb'
`/home/rubys/tmp/pre-corruption/test/unit/line_item_test.rb' -> `./test/unit/line_item_test.rb'
`/home/rubys/tmp/pre-corruption/test/performance/browsing_test.rb' -> `./test/performance/browsing_test.rb'
`/home/rubys/tmp/pre-corruption/test/fixtures/products.yml' -> `./test/fixtures/products.yml'
`/home/rubys/tmp/pre-corruption/test/fixtures/carts.yml' -> `./test/fixtures/carts.yml'
`/home/rubys/tmp/pre-corruption/test/fixtures/line_items.yml' -> `./test/fixtures/line_items.yml'
`/home/rubys/tmp/pre-corruption/test/fixtures/users.yml' -> `./test/fixtures/users.yml'
`/home/rubys/tmp/pre-corruption/test/fixtures/orders.yml' -> `./test/fixtures/orders.yml'
`/home/rubys/tmp/pre-corruption/test/test_helper.rb' -> `./test/test_helper.rb'
`/home/rubys/tmp/pre-corruption/test/functional/store_controller_test.rb' -> `./test/functional/store_controller_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/line_items_controller_test.rb' -> `./test/functional/line_items_controller_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/users_controller_test.rb' -> `./test/functional/users_controller_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/orders_controller_test.rb' -> `./test/functional/orders_controller_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/sessions_controller_test.rb' -> `./test/functional/sessions_controller_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/notifier_test.rb' -> `./test/functional/notifier_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/admin_controller_test.rb' -> `./test/functional/admin_controller_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/products_controller_test.rb' -> `./test/functional/products_controller_test.rb'
`/home/rubys/tmp/pre-corruption/test/functional/carts_controller_test.rb' -> `./test/functional/carts_controller_test.rb'
`/home/rubys/tmp/pre-corruption/vendor/plugins/.gitkeep' -> `./vendor/plugins/.gitkeep'
rm public/index.html
rake db:migrate
(in /home/rubys/tmp/work/corrupt)
==  CreateProducts: migrating =================================================
-- create_table(:products)
   -> 0.0037s
==  CreateProducts: migrated (0.0039s) ========================================
 
==  CreateCarts: migrating ====================================================
-- create_table(:carts)
   -> 0.0023s
==  CreateCarts: migrated (0.0025s) ===========================================
 
==  CreateLineItems: migrating ================================================
-- create_table(:line_items)
   -> 0.0029s
==  CreateLineItems: migrated (0.0031s) =======================================
 
==  AddQuantityToLineItem: migrating ==========================================
-- add_column(:line_items, :quantity, :integer, {:default=>1})
   -> 0.0149s
==  AddQuantityToLineItem: migrated (0.0151s) =================================
 
==  CombineItemsInCart: migrating =============================================
==  CombineItemsInCart: migrated (0.0206s) ====================================
 
==  AddPriceToLineItem: migrating =============================================
-- add_column(:line_items, :price, :decimal)
   -> 0.0017s
==  AddPriceToLineItem: migrated (0.0201s) ====================================
 
==  CreateOrders: migrating ===================================================
-- create_table(:orders)
   -> 0.0032s
==  CreateOrders: migrated (0.0034s) ==========================================
 
==  AddOrderIdToLineItem: migrating ===========================================
-- add_column(:line_items, :order_id, :integer)
   -> 0.0016s
==  AddOrderIdToLineItem: migrated (0.0018s) ==================================
 
==  CreateUsers: migrating ====================================================
-- create_table(:users)
   -> 0.0030s
==  CreateUsers: migrated (0.0031s) ===========================================
 
rake db:seed
(in /home/rubys/tmp/work/corrupt)

Start the server.

Add to cart

get /
Your Cart
Total $0.00
Home
Questions
News
Contact

Your Pragmatic Catalog

Ruby

Programming Ruby 1.9

Ruby is the fastest growing and most exciting dynamic language out there. If you need to get working programs delivered fast, you should add Ruby to your toolbox.

$49.50
Rtp

Rails Test Prescriptions

Rails Test Prescriptions is a comprehensive guide to testing Rails applications, covering Test-Driven Development from both a theoretical perspective (why to test) and from a practical perspective (how to test effectively). It covers the core Rails testing tools and procedures for Rails 2 and Rails 3, and introduces popular add-ons, including Cucumber, Shoulda, Machinist, Mocha, and Rcov.

$43.75
Wd4d

Web Design for Developers

Web Design for Developers will show you how to make your web-based application look professionally designed. We'll help you learn how to pick the right colors and fonts, avoid costly interface and accessibility mistakes -- your application will really come alive. We'll also walk you through some common Photoshop and CSS techniques and work through a web site redesign, taking a new design from concept all the way to implementation.

$42.95
post /line_items?product_id=3
  • product_id => 3
You are being redirected.
get http://localhost:3000/
Your Cart
Rails Test Prescriptions $43.75
Total $43.75
Home
Questions
News
Contact

Your Pragmatic Catalog

Ruby

Programming Ruby 1.9

Ruby is the fastest growing and most exciting dynamic language out there. If you need to get working programs delivered fast, you should add Ruby to your toolbox.

$49.50
Rtp

Rails Test Prescriptions

Rails Test Prescriptions is a comprehensive guide to testing Rails applications, covering Test-Driven Development from both a theoretical perspective (why to test) and from a practical perspective (how to test effectively). It covers the core Rails testing tools and procedures for Rails 2 and Rails 3, and introduces popular add-ons, including Cucumber, Shoulda, Machinist, Mocha, and Rcov.

$43.75
Wd4d

Web Design for Developers

Web Design for Developers will show you how to make your web-based application look professionally designed. We'll help you learn how to pick the right colors and fonts, avoid costly interface and accessibility mistakes -- your application will really come alive. We'll also walk you through some common Photoshop and CSS techniques and work through a web site redesign, taking a new design from concept all the way to implementation.

$42.95

Place the order

get /orders/new
Your Cart
Rails Test Prescriptions $43.75
Total $43.75
Home
Questions
News
Contact
Please Enter Your Details




post /orders
  • order[pay_type] => Check
  • order[address] => 123 Main St., Anytown USA
  • order[email] => juser@hotmail.com
  • order[name] => Joe User
You are being redirected.
get http://localhost:3000/

ActiveRecord::StatementInvalid in Store#index

Showing /home/rubys/tmp/work/corrupt/app/views/carts/_cart.html.erb where line #3 raised:

SQLite3::CorruptException: database disk image is malformed: SELECT "line_items".* FROM "line_items" WHERE ("line_items".cart_id = 3)

Extracted source (around line #3):

1: <div class="cart_title">Your Cart</div>
2: <table>
3:   <%= render(cart.line_items) %>
4: 
5:   <tr class="total_line">
6:     <td colspan="2">Total</td>

Trace of template inclusion: app/views/layouts/application.html.erb

Rails.root: /home/rubys/tmp/work/corrupt

Application Trace | Framework Trace | Full Trace
app/views/carts/_cart.html.erb:3:in `_app_views_carts__cart_html_erb___1649143720_70122340269080'
app/views/layouts/application.html.erb:21:in `_app_views_layouts_application_html_erb__196897063_70122340806540'

Request

Parameters:

None

Show session dump

Show env dump

Response

Headers:

None

Ticket 6125 : SQLite3::CorruptException: database disk image is malformed

Environment

Tue, 07 Dec 2010 22:26:57 GMT
/home/rubys/.rvm/rubies/ruby-1.8.7-p302/bin/ruby -v
ruby 1.8.7 (2010-08-16 patchlevel 302) [x86_64-linux]
gem -v
1.3.7
bundle show
Gems included by the bundle:
  * abstract (1.0.0)
  * actionmailer (3.1.0.beta)
  * actionpack (3.1.0.beta)
  * activemodel (3.1.0.beta)
  * activerecord (3.1.0.beta)
  * activeresource (3.1.0.beta)
  * activesupport (3.1.0.beta)
  * arel (2.0.7.beta.20101201093009 89194f5)
  * builder (3.0.0)
  * bundler (1.0.7)
  * erubis (2.6.6)
  * i18n (0.5.0)
  * mail (2.2.12)
  * mime-types (1.16)
  * polyglot (0.3.1)
  * rack (1.2.1 85ca454)
  * rack-cache (0.5.3)
  * rack-mount (0.6.13)
  * rack-test (0.5.6)
  * rails (3.1.0.beta 7c92063)
  * railties (3.1.0.beta)
  * rake (0.8.7)
  * sqlite3-ruby (1.3.2)
  * thor (0.14.6)
  * treetop (1.4.9)
  * tzinfo (0.3.23)
  * will_paginate (3.0.pre2)
rake about
(in /home/rubys/tmp/work/corrupt)
About your application's environment
Ruby version              1.8.7 (x86_64-linux)
RubyGems version          1.3.7
Rack version              1.2
Rails version             3.1.0.beta
Active Record version     3.1.0.beta
Action Pack version       3.1.0.beta
Active Resource version   3.1.0.beta
Action Mailer version     3.1.0.beta
Active Support version    3.1.0.beta
Application root          /home/rubys/tmp/work/corrupt
Environment               development
git log -1
commit 7c920631ec3b314cfaa3a60d265de40cba3e8135
Author: Santiago Pastorino <santiago@wyeworks.com>
Date:   Sun Dec 5 13:26:14 2010 -0200

    Test using default option as symbol added for human_attribute_name