for reason unknown, the failure happens as expected if one adds a call to chain.GetEntries() prior to looping.
Merge pull request #158 from elaird/chain-test-force-fail

for reason unknown, the failure happens as expected...