Brazil granted a tourist visa on Wednesday to Yoani Sánchez, a dissident Cuban author and blogger, ahead of a trip to Cuba this month by Brazil’s president, Dilma Rousseff. The request by Ms. Sánchez to travel to Brazil for the screening of a documentary had emerged as a test of Cuba’s restrictive travel policies for its own citizens and Brazil’s willingness to prod a friendly government on a prominent human rights issue. Ms. Sánchez, 36, had appealed personally for the visa to Ms. Rousseff, a former member of an urban guerrilla cell, referring to a photograph made public in December that showed Ms. Rousseff as a young woman being questioned at a military hearing by men whose faces were covered. It remains to be seen whether Cuba will allow her to travel to Brazil.