Adapting the spell caster script to WebDriver