changed p to span to make tests pass