Check JSDOM getAttribute behavior an bail out if out of date

An out-of-date JSDOM version (< 0.4.x) will result in random failures as
getAttribute for non-existing keys returns the empty string instead of null.
Test for this and bail out with a helpful message if that is the case.

Change-Id: I9375d6dd74415de3a5ddbe20ea3526ed6d078c00
Merge "Check JSDOM getAttribute behavior an bail out if out of date"