Added two calls to PHPUnit_Framework_TestResult::endTestSuite() from PHPUnit_Framework_TestSuite::run() to make sure test suites are ended properly when an exception (e.g. PHPUnit_Framework_SkippedTestError) in a test's setUpBeforeClass() method
Whitespace fixes
When one test creates a mock object, sets staticExpectation and throws an unexpected exception afterwards, the state of the mock object class, which is saved in a static member variable, is not cleaned up before invoking the next test. This can cause the next test which sets another staticExpectation on the same class to fail.

See https://github.com/sebastianbergmann/phpunit/issues/1143 for more details and an example test that demonstrates this issue.

The fix is to clean up the mock objects' state after each test is run or an exception is caught.
Make PhpStorm happy by giving the $delta argument an actual float as its default value
Fix whitespace
Improve comparison of DOMNode objects
Merge branch '4.0' into 4.1
Merge branch '4.1'
Fix: serialization of test suits static properties

When --backupStaticAttributes switch is set static properties of classes derived from PHPUnit_Framework_Test are also backed up due to wrong use of instanceof.

<string> instanceof <object>|<class>|<string> is always false. One should use is_a(<stringClassName>, <stringClassName>, true).

This bug affect all versions of PHPUnit that uses PHPUnit_Util_GlobalState class.
fixed compatibility issue with PHP 5.3.3

is_a in PHP 5.3.3 does not support third parameter (allow_string) thus $object parameter cannot be string.
+++ test of test case static property preservation
typo fix
Merge branch '4.0' into 4.1
Merge branch '4.1'
Merge pull request #1142 from GrahamCampbell/tweaks

Whitespace Fixes
Merge branch '3.7' into 4.0
Merge branch '4.0' into 4.1
Merge branch '4.1'
Don't Overwrite Already Existing Environment Vars

Closes #1181

If a variable is already set via `putenv` or if the variable is already
present in the `$_ENV` array, it will no longer be ovewritten by
`PHPUnit_Util_Configuration::handlePHPConfiguration`.

This allows users to pass in environment variables fia the command line
in the usual ways:

    bash$ SOME_VAR="a value" ./path/to/phpunit
Merge branch '4.0' into 4.1