Created
November 22, 2013 17:43
-
-
Save zetas/7603965 to your computer and use it in GitHub Desktop.
Lol, i've gone a little crazy methinks.
This file contains hidden or 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
bundle exec rspec | |
[Report a Problem]0 min 9 sec | |
ActiveRecord::SchemaMigration Load (0.6ms) [1mSELECT "schema_migrations".* FROM "schema_migrations" | |
TodosController | |
POST create | |
with valid params | |
[1m (2.2ms) BEGIN | |
Processing by TodosController#create as HTML | |
Parameters: {"todo"=>{"title"=>"MyString"}} | |
[1m (0.2ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (55.5ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.9ms) [1mRELEASE SAVEPOINT active_record_1 | |
Redirected to http://test.host/todos/1 | |
Completed 302 Found in 81ms (ActiveRecord: 58.6ms) | |
[1mTodo Load (1.6ms) SELECT "todos".* FROM "todos" ORDER BY "todos"."id" DESC LIMIT 1 | |
[1m (0.3ms) [1mROLLBACK | |
redirects to the created todo | |
[1m (0.2ms) BEGIN | |
Processing by TodosController#create as HTML | |
Parameters: {"todo"=>{"title"=>"MyString"}} | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.7ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.3ms) [1mRELEASE SAVEPOINT active_record_1 | |
Redirected to http://test.host/todos/2 | |
Completed 302 Found in 5ms (ActiveRecord: 1.1ms) | |
[1m (0.2ms) ROLLBACK | |
assigns a newly created todo as @todo | |
[1m (0.2ms) [1mBEGIN | |
[1m (0.5ms) SELECT COUNT(*) FROM "todos" | |
Processing by TodosController#create as HTML | |
Parameters: {"todo"=>{"title"=>"MyString"}} | |
[1m (0.2ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.5ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.4ms) [1mRELEASE SAVEPOINT active_record_1 | |
Redirected to http://test.host/todos/3 | |
Completed 302 Found in 5ms (ActiveRecord: 1.1ms) | |
[1m (0.9ms) SELECT COUNT(*) FROM "todos" | |
[1m (0.2ms) [1mROLLBACK | |
creates a new Todo | |
with invalid params | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mROLLBACK | |
assigns a newly created but unsaved todo as @todo (FAILED - 1) | |
[1m (0.7ms) BEGIN | |
[1m (0.3ms) [1mROLLBACK | |
re-renders the 'new' template (FAILED - 2) | |
GET index | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.6ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.8ms) [1mRELEASE SAVEPOINT active_record_1 | |
Processing by TodosController#index as HTML | |
Completed 200 OK in 51ms (Views: 50.4ms | ActiveRecord: 0.0ms) | |
[1mTodo Load (0.5ms) SELECT "todos".* FROM "todos" | |
[1m (0.3ms) [1mROLLBACK | |
assigns all todos as @todos | |
DELETE destroy | |
[1m (0.1ms) BEGIN | |
[1m (0.2ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.5ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.1ms) [1mRELEASE SAVEPOINT active_record_1 | |
[1m (0.2ms) SELECT COUNT(*) FROM "todos" | |
Processing by TodosController#destroy as HTML | |
Parameters: {"id"=>"5"} | |
[1mTodo Load (0.7ms) [1mSELECT "todos".* FROM "todos" WHERE "todos"."id" = $1 LIMIT 1 [["id", "5"]] | |
[1m (0.1ms) SAVEPOINT active_record_1 | |
[1mSQL (0.4ms) [1mDELETE FROM "todos" WHERE "todos"."id" = $1 [["id", 5]] | |
[1m (0.1ms) RELEASE SAVEPOINT active_record_1 | |
Redirected to http://test.host/todos | |
Completed 302 Found in 7ms (ActiveRecord: 1.3ms) | |
[1m (0.3ms) [1mSELECT COUNT(*) FROM "todos" | |
[1m (0.2ms) ROLLBACK | |
destroys the requested todo | |
[1m (0.1ms) [1mBEGIN | |
[1m (0.2ms) SAVEPOINT active_record_1 | |
[1mSQL (0.5ms) [1mINSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.1ms) RELEASE SAVEPOINT active_record_1 | |
Processing by TodosController#destroy as HTML | |
Parameters: {"id"=>"6"} | |
[1mTodo Load (0.3ms) [1mSELECT "todos".* FROM "todos" WHERE "todos"."id" = $1 LIMIT 1 [["id", "6"]] | |
[1m (0.1ms) SAVEPOINT active_record_1 | |
[1mSQL (0.2ms) [1mDELETE FROM "todos" WHERE "todos"."id" = $1 [["id", 6]] | |
[1m (0.2ms) RELEASE SAVEPOINT active_record_1 | |
Redirected to http://test.host/todos | |
Completed 302 Found in 4ms (ActiveRecord: 0.9ms) | |
[1m (0.2ms) [1mROLLBACK | |
redirects to the todos list | |
GET edit | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.5ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.2ms) [1mRELEASE SAVEPOINT active_record_1 | |
Processing by TodosController#edit as HTML | |
Parameters: {"id"=>"7"} | |
[1mTodo Load (0.4ms) SELECT "todos".* FROM "todos" WHERE "todos"."id" = $1 LIMIT 1 [["id", "7"]] | |
Completed 200 OK in 3ms (Views: 1.4ms | ActiveRecord: 0.4ms) | |
[1m (0.2ms) [1mROLLBACK | |
assigns the requested todo as @todo | |
GET show | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.5ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.2ms) [1mRELEASE SAVEPOINT active_record_1 | |
Processing by TodosController#show as HTML | |
Parameters: {"id"=>"8"} | |
[1mTodo Load (0.5ms) SELECT "todos".* FROM "todos" WHERE "todos"."id" = $1 LIMIT 1 [["id", "8"]] | |
Completed 200 OK in 3ms (Views: 1.6ms | ActiveRecord: 0.5ms) | |
[1m (0.3ms) [1mROLLBACK | |
assigns the requested todo as @todo | |
PUT update | |
with valid params | |
[1m (0.2ms) BEGIN | |
[1m (0.2ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.6ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.2ms) [1mRELEASE SAVEPOINT active_record_1 | |
Processing by TodosController#update as HTML | |
Parameters: {"todo"=>{"title"=>"MyString"}, "id"=>"9"} | |
[1mTodo Load (0.4ms) SELECT "todos".* FROM "todos" WHERE "todos"."id" = $1 LIMIT 1 [["id", "9"]] | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1m (0.2ms) RELEASE SAVEPOINT active_record_1 | |
Redirected to http://test.host/todos/9 | |
Completed 302 Found in 6ms (ActiveRecord: 0.7ms) | |
[1m (0.1ms) [1mROLLBACK | |
redirects to the todo | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (0.5ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.1ms) [1mRELEASE SAVEPOINT active_record_1 | |
Processing by TodosController#update as HTML | |
Parameters: {"todo"=>{"title"=>"MyString"}, "id"=>"10"} | |
[1mTodo Load (0.3ms) SELECT "todos".* FROM "todos" WHERE "todos"."id" = $1 LIMIT 1 [["id", "10"]] | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1m (0.1ms) RELEASE SAVEPOINT active_record_1 | |
Redirected to http://test.host/todos/10 | |
Completed 302 Found in 6ms (ActiveRecord: 0.5ms) | |
[1m (0.3ms) [1mROLLBACK | |
assigns the requested todo as @todo | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (2.4ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (2.3ms) [1mRELEASE SAVEPOINT active_record_1 | |
[1m (2.5ms) ROLLBACK | |
updates the requested todo (FAILED - 3) | |
with invalid params | |
[1m (0.4ms) [1mBEGIN | |
[1m (0.1ms) SAVEPOINT active_record_1 | |
[1mSQL (0.5ms) [1mINSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (0.1ms) RELEASE SAVEPOINT active_record_1 | |
[1m (0.1ms) [1mROLLBACK | |
assigns the todo as @todo (FAILED - 4) | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mSAVEPOINT active_record_1 | |
[1mSQL (1.6ms) INSERT INTO "todos" ("created_at", "title", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00], ["title", "MyString"], ["updated_at", Fri, 22 Nov 2013 17:41:56 UTC +00:00]] | |
[1m (2.2ms) [1mRELEASE SAVEPOINT active_record_1 | |
[1m (5.6ms) ROLLBACK | |
re-renders the 'edit' template (FAILED - 5) | |
GET new | |
[1m (0.2ms) [1mBEGIN | |
Processing by TodosController#new as HTML | |
Completed 200 OK in 7ms (Views: 6.7ms | ActiveRecord: 0.0ms) | |
[1m (0.8ms) ROLLBACK | |
assigns a new todo as @todo | |
todos/edit | |
[1m (0.4ms) [1mBEGIN | |
[1m (0.3ms) ROLLBACK | |
renders the edit todo form (FAILED - 6) | |
Todos | |
GET /todos | |
[1m (0.2ms) [1mBEGIN | |
Started GET "/todos" for 127.0.0.1 at 2013-11-22 17:41:57 +0000 | |
Processing by TodosController#index as HTML | |
[1mTodo Load (0.8ms) SELECT "todos".* FROM "todos" | |
Completed 200 OK in 526ms (Views: 505.6ms | ActiveRecord: 0.8ms) | |
[1m (0.3ms) [1mROLLBACK | |
works! (now write some real specs) | |
TodosHelper | |
add some examples to (or delete) /home/rof/src/bitbucket.org/zetas/project-sol/spec/helpers/todos_helper_spec.rb (PENDING: No reason given) | |
Todo | |
[1m (0.4ms) BEGIN | |
[1m (0.2ms) [1mROLLBACK | |
is invalid without a title | |
todos/index | |
[1m (1.7ms) BEGIN | |
[1m (1.8ms) [1mROLLBACK | |
renders a list of todos (FAILED - 7) | |
TodosController | |
routing | |
[1m (1.8ms) BEGIN | |
[1m (1.9ms) [1mROLLBACK | |
routes to #create | |
[1m (2.5ms) BEGIN | |
[1m (0.1ms) [1mROLLBACK | |
routes to #index | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mROLLBACK | |
routes to #destroy | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mROLLBACK | |
routes to #edit | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mROLLBACK | |
routes to #new | |
[1m (0.2ms) BEGIN | |
[1m (0.1ms) [1mROLLBACK | |
routes to #update | |
[1m (0.1ms) BEGIN | |
[1m (0.2ms) [1mROLLBACK | |
routes to #show | |
todos/show | |
[1m (0.1ms) BEGIN | |
[1m (0.1ms) [1mROLLBACK | |
renders attributes in <p> (FAILED - 8) | |
todos/new | |
[1m (0.2ms) BEGIN | |
[1m (0.5ms) [1mROLLBACK | |
renders new todo form (FAILED - 9) | |
Pending: | |
TodosHelper add some examples to (or delete) /home/rof/src/bitbucket.org/zetas/project-sol/spec/helpers/todos_helper_spec.rb | |
# No reason given | |
# ./spec/helpers/todos_helper_spec.rb:14 | |
Failures: | |
1) TodosController POST create with invalid params assigns a newly created but unsaved todo as @todo | |
Failure/Error: Todo.any_instance.stub(:save).and_return(false) | |
NoMethodError: | |
undefined method `stub' for #<Mocha::ClassMethods::AnyInstance:0x00000003f720f8> | |
# ./spec/controllers/todos_controller_spec.rb:87:in `block (4 levels) in <top (required)>' | |
2) TodosController POST create with invalid params re-renders the 'new' template | |
Failure/Error: Todo.any_instance.stub(:save).and_return(false) | |
NoMethodError: | |
undefined method `stub' for #<Mocha::ClassMethods::AnyInstance:0x00000003f720f8> | |
# ./spec/controllers/todos_controller_spec.rb:94:in `block (4 levels) in <top (required)>' | |
3) TodosController PUT update with valid params updates the requested todo | |
Failure/Error: Todo.any_instance.should_receive(:update).with({ "title" => "MyString" }) | |
NoMethodError: | |
undefined method `should_receive' for #<Mocha::ClassMethods::AnyInstance:0x00000003f720f8> | |
# ./spec/controllers/todos_controller_spec.rb:109:in `block (4 levels) in <top (required)>' | |
4) TodosController PUT update with invalid params assigns the todo as @todo | |
Failure/Error: Todo.any_instance.stub(:save).and_return(false) | |
NoMethodError: | |
undefined method `stub' for #<Mocha::ClassMethods::AnyInstance:0x00000003f720f8> | |
# ./spec/controllers/todos_controller_spec.rb:130:in `block (4 levels) in <top (required)>' | |
5) TodosController PUT update with invalid params re-renders the 'edit' template | |
Failure/Error: Todo.any_instance.stub(:save).and_return(false) | |
NoMethodError: | |
undefined method `stub' for #<Mocha::ClassMethods::AnyInstance:0x00000003f720f8> | |
# ./spec/controllers/todos_controller_spec.rb:138:in `block (4 levels) in <top (required)>' | |
6) todos/edit renders the edit todo form | |
Failure/Error: @todo = assign(:todo, stub_model(Todo, | |
NoMethodError: | |
undefined method `proxy_for' for nil:NilClass | |
# ./spec/views/todos/edit.html.erb_spec.rb:5:in `block (2 levels) in <top (required)>' | |
7) todos/index renders a list of todos | |
Failure/Error: stub_model(Todo, | |
NoMethodError: | |
undefined method `proxy_for' for nil:NilClass | |
# ./spec/views/todos/index.html.erb_spec.rb:6:in `block (2 levels) in <top (required)>' | |
8) todos/show renders attributes in <p> | |
Failure/Error: @todo = assign(:todo, stub_model(Todo, | |
NoMethodError: | |
undefined method `proxy_for' for nil:NilClass | |
# ./spec/views/todos/show.html.erb_spec.rb:5:in `block (2 levels) in <top (required)>' | |
9) todos/new renders new todo form | |
Failure/Error: assign(:todo, stub_model(Todo, | |
NoMethodError: | |
undefined method `proxy_for' for nil:NilClass | |
# ./spec/views/todos/new.html.erb_spec.rb:5:in `block (2 levels) in <top (required)>' | |
Finished in 1.17 seconds | |
30 examples, 9 failures, 1 pending | |
Failed examples: | |
rspec ./spec/controllers/todos_controller_spec.rb:85 # TodosController POST create with invalid params assigns a newly created but unsaved todo as @todo | |
rspec ./spec/controllers/todos_controller_spec.rb:92 # TodosController POST create with invalid params re-renders the 'new' template | |
rspec ./spec/controllers/todos_controller_spec.rb:103 # TodosController PUT update with valid params updates the requested todo | |
rspec ./spec/controllers/todos_controller_spec.rb:127 # TodosController PUT update with invalid params assigns the todo as @todo | |
rspec ./spec/controllers/todos_controller_spec.rb:135 # TodosController PUT update with invalid params re-renders the 'edit' template | |
rspec ./spec/views/todos/edit.html.erb_spec.rb:12 # todos/edit renders the edit todo form | |
rspec ./spec/views/todos/index.html.erb_spec.rb:19 # todos/index renders a list of todos | |
rspec ./spec/views/todos/show.html.erb_spec.rb:12 # todos/show renders attributes in <p> | |
rspec ./spec/views/todos/new.html.erb_spec.rb:12 # todos/new renders new todo form | |
Randomized with seed 61253 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment