ruby - how to examine contents of database during or after rails integration test -


i'm experienced dev i'm total web , rails newbie. i'm trying implement kind of market place rails application. i've developed app i'm far along in customer interaction flow , i'm realizing need automate stuff cause dev/test via browser consumes time.

say have customer interaction flow goes page a, page b, c, d...g. , i'm developing 'h' page. know use automated test facilities (e.g. minitest) automate whole thing. being how still have rails training wheels on see database state progress 1 state next myself rather trust test automation doing i'm expecting.

my question is, there way have minitest automate/simulate user interaction flow -> g , let me take on in manual way there such click newly-developed browser button while using db browser watch db state progress appropriately?

if not - i'm guessing - i'd happily settle way examine database contents after integration test. integration tests work fine. it's after complete i'd able pop open db browser , poke around, verifying various values ensure satisfaction things in db should be.

another possible solution work me if there within integration tests access db values verify things programmatically. have in mind how assigns give access instance variables within integration tests can 'asserts' calls on.

and, of course, please let me know if i'm way off track , there's "best practice" type of thing i've missed.

i'm using rails 4.2.0 , ruby 2.2.2p95

while minitest doesn't have way first option mentioned, might checkout watir means of (partially) automating tests leave off @ point browser still open , continue manually while watching what's going on in db.

however, since second option mentioned possible minitest (and save more time being automated) i'd highly recommend it. see ruby on rails tutorial 3rd edition michael hartl examples (you might find whole thing helpful, here's section shows test looking for: section 7.4.4.)


Comments

Popular posts from this blog

facebook - android ACTION_SEND to share with specific application only -

python - Creating a new virtualenv gives a permissions error -

javascript - cocos2d-js draw circle not instantly -