Audit excluded tests on JRuby and address differences

Aberta
#1,123 1 comentário 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
4/5
Tempo estimado
3-5 dias
Facilidade para iniciantes
48/100
Tipo de issue
Bug
Clareza
Razoavelmente clara
Status de atividade
Ativa
Stack de tecnologia
ruby
Domínio
backend

Direção de pesquisa

Start by running the listed JRuby-excluded tests under JRuby and compare their behavior with the C extension; inspect the conditionals and omissions in test/json/json_generator_test.rb, test/json/json_minefield_parser_test.rb, test/json/json_parser_test.rb, and test/json/resumable_parser_test.rb. Use #1122 as the example of a latent bug. Done means fixing the applicable Java extension differences and restoring the corresponding tests, while identifying exclusions that remain valid.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

Several tests still explicitly exclude JRuby and do not run against the Java extension. We should reexamine these and fix as many differences with the C extension as possible.

$ git grep -e "RUBY_ENGINE == [\"']jruby" test 
test/json/json_generator_test.rb:    if RUBY_ENGINE == "jruby"
test/json/json_minefield_parser_test.rb:  if RUBY_ENGINE == 'jruby'
test/json/json_parser_test.rb:    unless RUBY_ENGINE == 'jruby'
test/json/json_parser_test.rb:    omit "JRuby errors don't contain positions" if RUBY_ENGINE == "jruby"
test/json/json_parser_test.rb:    omit "JRuby errors don't contain positions" if RUBY_ENGINE == "jruby"
test/json/json_parser_test.rb:    omit "JRuby string decoding errors don't contain positions" if RUBY_ENGINE == "jruby"
test/json/resumable_parser_test.rb:    omit "JRuby not supported" if RUBY_ENGINE == "jruby"

Some of these may be valid but most involve changes made to the C extension that were never ported to the Java extension. That last one excludes all of the ResumableParser tests because that entire feature is missing from the Java extension.

See #1122 for one example of a latent bug hidden by these masks.

Linguagem predominante
Ruby
Estrelas
785
Forks
389
Merge médio
6h 32min
PRs com merge (30d)
22

Preparar o ambiente

Este projeto não oferece contêiner de desenvolvimento, Dockerfile nem guia de contribuição, então a configuração fica por sua conta: comece pelo README e veja nosso guia da primeira contribuição para os passos gerais.

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de ruby/json

Todas as issues de ruby/json

Issues semelhantes

Mais issues de Ruby

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.