Show/hide reference warnings on delete and add/rename questions

http://manage.dimagi.com/default.asp?137480

Other minor changes in this PR:
- 6ab1b21 make tests run faster. YES!
- 3839323 @emord reported that his dev/test setup was using the built version when running stand-alone. This turned out to be because his test page URL did not contain the string "localhost". The logic for detecting when to use the built version could be simplified since we are not using heroku for testing anymore.
This prevents change (mug rename, etc.) handlers from updating logic expressions during the loading phase.

It also cuts about 10 seconds (!!) off of the load time for the huge form profiling test.