Loop tests added. They fail for now. It seems easy to do loops. Other minor changes.