updated tests for better insertBefore()