Updated pwb.py to better mirror direct script runs

Before, execfile() ran the script in environment that pwb.py has, which
included os and path imports, and several other variables.

This commit uses run_python_file from Ned Batchelors' coverage.py [1],
available under the BSD license [2]. See also his blog posts on the
subject [3,4].

This commit also adds a test that shells out to compare the locals()
for runs through pwb.py as well as to a script directly.

After this change, the effects of changeset 76484 can be seen using pwb.py

[1] https://bitbucket.org/ned/coveragepy/src/b5abcee50dbe/coverage/execfile.py
[2] https://bitbucket.org/ned/coveragepy/src/2c5fb3a8b81cc56d8ad57dd1bd83ef7740f0d65d/setup.py?at=default
[3] http://nedbatchelder.com/blog/200904/running_a_python_file_as_main.html
[4] http://nedbatchelder.com/blog/200905/running_a_python_file_as_main_take_2.html

Change-Id: If9458fca50f07f08441dbb6e06f78bdbae2065de
Merge "Updated pwb.py to better mirror direct script runs"