createPseudoElement() method and use this method in animate() tests