6f) Tips & Tricks
The latest versions of chrome seem to be incompatible with the version of Sahi that is included in CWB. Download a self-extracting zip file here. Extract it to a folder on your harddisk. Afterwards, edit the browser_types.xml included in your sahi installation (usually in C:\sahi-5.0\userdata\config). All references to Chrome should be changed to point to the chrome.exe file of your newly extracted zip file.
- When working with login tests: make sure to log out at the end of a scenario. That way, all scenario's can use login steps from a clean status.Â
- When testing in CHROME : the sahi chrome version seems to have caching. If you experience issues with selecting brand new code, try to pause the scenario and do a hard refresh.Â
- Easy way to change default test settings: - make a directory "dev-configs" in the user home directory of your pc and then make a file "ctf.local.properties". then  specify:fe. browser=chrome  or environment=development Â
- To start testing start sahi first! Go to c:\sahi\bin \dashboard.bat
- To pause the execution of a scenario and to prevent the browser from closing when an error occurs (esp useful in development), you can either add the tag  '@pauseOnError'  to your scenario/feature or you can set the system property 'onpause.error' to 'true'. For this feature to work you need the IntelliJReporter as your console output formatter ( program argument: --format com.foreach.cuke.core.formatter.IntelliJReporter)
If you cannot find elements on HTTPS websites:
I.g.v. Chrome add start optionÂ
--ignore-certificate-errors
 in the file Â<SAHI_HOME>\userdata\config\browser_types.xml
. Reboot SAHI. A number of popular Chrome options are:<options>--user-data-dir=$userDir\browser\chrome\profiles\sahi$threadNo --proxy-server=localhost:19999 --disable-popup-blocking --disable-save-password-bubble --disable-translate --ignore-certificate-errors --disable-client-side-phishing-detection</options>
Consult http://peter.sh/experiments/chromium-command-line-switches/Â for a complete listÂ
 Other browsers may have the same options, but we didn't look them up.