Anglo Irish Bank posts €17.7bn loss ahead of stress tests