ReportBuilder icon indicating copy to clipboard operation
ReportBuilder copied to clipboard

Display in report shows broken characters. (Report_builder)

Open valeriaA opened this issue 3 years ago • 2 comments

I configured to display the report:

at_exit do
    $driver.driver_quit

ReportBuilder.input_path = 'reports/emissaoDeApolice.json'
    
ReportBuilder.configure do |config|
  config.report_path = 'resultsReportBuilder/my_test_report'
  config.report_types = [:json, :html]
end

options = {
   report_title: 'My Test Results'
}

ReportBuilder.build_report options
end

But when I checked the report I noticed that it prints characters that are not expected, they are not part of the text. It looks like an encoding problem.

image

Does anyone know what can it be? And how can this be resolved?

Thanks a lot.

valeriaA avatar Aug 12 '21 20:08 valeriaA

Opa, você tentou colocar #encoding: utf-8 no topo do arquivo .feature?

#encoding: utf-8

GabrielForchesatto avatar Aug 29 '21 22:08 GabrielForchesatto

Opa, você tentou colocar #encoding: utf-8 no topo do arquivo .feature?

#encoding: utf-8

Opa, sim tem o encoding utf-8 na minha feature, eu descobrir oq era, estou usando o colorize para que na saída do terminal fique uma visualização melhor mas quando gera o report JSON ele "escreve o código das cores" em json, só que quando o report_builder vai ler o JSON para gerar o relatório ele não interpreta aquele código como cores, aí ele imprime o que ta escrito.

Quando eu tiro o colorize os caracteres incorretos são removidos do report_builder é chato porque a saída no terminal estava muito legal, categorizado por cores.

valeriaA avatar Aug 30 '21 18:08 valeriaA