[rspec-users] Cucumber Scaffolds

Andrew Premdas apremdas at gmail.com
Thu Nov 13 01:03:52 EST 2008


A couple of tips may help here.

1) You can debug features by putting 'debugger' in the step file. Just
make sure there is a line after debugger

e.g

...
  debugger
  response
end

If there's nothing after debugger you will stop in the cucumber code,
which is not what you want.

2) You can also put debugger statements in your rails files. Perhaps
you could do a

<%- debugger %>

before you render your partial in the form. (You might have to use <%=)

HTH

Andrew


2008/11/12 James B. Byrne <byrnejb at harte-lyne.ca>:
>
> For what it is worth the contents of the log/test.log file are:
>
> $ tail log/test.log
> Completed in 67ms (View: 7, DB: 2) | 200 OK [http://www.example.com/entities]
>  SQL (0.7ms)   SELECT count(*) AS count_all FROM "entities"
> REQUESTING PAGE: GET /entities/new with {} and HTTP headers {}
>
>
> Processing EntitiesController#new (for 127.0.0.1 at 2008-11-12 15:11:44)
> [GET]
>  Session ID: 04a1f0098c54dba8a812645fbb015380
>  Parameters: {"action"=>"new", "controller"=>"entities"}
> Rendering template within layouts/application
> Rendering entities/new
>
> While, the same page rendered in Firefox using the development environment
> shows this:
>
> REQUESTING PAGE: GET /entities/new with {} and HTTP headers {}
>
>
> Processing EntitiesController#new (for 127.0.0.1 at 2008-11-12 15:11:44)
> [GET]
>  Session ID: 04a1f0098c54dba8a812645fbb015380
>  Parameters: {"action"=>"new", "controller"=>"entities"}
> Rendering template within layouts/application
> Rendering entities/new
> [byrnejb at inet02 proforma.git]$ tail log/development.log
> Rendering template within layouts/application
> Rendering entities/new
> Rendered entities/_entity_header (15.2ms)
> Completed in 98ms (View: 57, DB: 0) | 200 OK [http://localhost/entities/new]
>  SQL (4.3ms)    SELECT name
>  FROM sqlite_master
>  WHERE type = 'table' AND NOT name = 'sqlite_sequence'
>
>  SQL (1.1ms)   SELECT version FROM schema_migrations
>  SQL (1.7ms)   SELECT version FROM schema_migrations
>
> I really could use from help from someone who can explain this behaviour.
>
>
>
>
> --
> ***          E-Mail is NOT a SECURE channel          ***
> James B. Byrne                mailto:ByrneJB at Harte-Lyne.ca
> Harte & Lyne Limited          http://www.harte-lyne.ca
> 9 Brockley Drive              vox: +1 905 561 1241
> Hamilton, Ontario             fax: +1 905 561 0757
> Canada  L8E 3C3
>
> _______________________________________________
> rspec-users mailing list
> rspec-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users
>


More information about the rspec-users mailing list