[github-197] Modify test class HeapDump to allow it work in different JDKs. Thanks to Marius Volkhart. This closes #197