Test variable reference parsing