Fix failing test in older IE

In older IE, `for` enumerate internal properties.
Merge pull request #2734 from tricknotes/fix-failing-test-in-ie8

Fix failing test in older IE