Add spin_assert to make selenium test more robust