n1k0/casperjs — Issue #39: Start removes set cookies? 
Author: srhyne
Created: 2012-01-13 19:33:23+00:00
State: open

Hi Nicolas,

This is probably not a bug but rather a feature ;).

[In your response to my comments](https://github.com/n1k0/casperjs/commit/f0b8a38ae09e8b30a3f807e86d6b9e04a8974755#commitcomment-864742)

You mention that I should make my tests more atomic using .start to clear out casper settings. I checked casper.prototype.start and I see how you clear out the page DOM. (goes to about:blank location right?). However, what if you need to maintain sessions? It looks like start removes cookies as well or is that not the case?

My thought is that new phantom.Casper would be a new cookie jar not casper.start? [Right now my tests are looking like this](https://skitch.com/rhyne14/g2ude/git-webpdi-tests-1) because I am doing exactly what you said NOT to do (using start and run only once ;). Of course this method makes it so that I can only run all my tests or none.