Make filename optional & add ScriptText property. Refs #8599.
Updated unit test to verify ScriptText is correct. Refs #8599.
Merge branch 'feature/8599_improve_python_hist_script' into develop