Repository navigation
Bring the HTML reporter into Rubytest - #14
Merged
Merged
Conversation
Add rubytest/rake with Test::Rake::TestTask, from rubytest-rake 0.2.0. Check the forked run's exit status, so the task fails when the run does: rubytest-rake waited for the child and then always exited 0. Use only the default globs that match a file, since the runner now fails a glob that matches nothing. Let TEST replace the task's files for one invocation. Drop the shell mode, which called an undefined method. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
rubytest-html's reporter predates the recorder and no longer loads. Rewrite it on record and finish: one self-contained document, written when the run finishes, with results nested under their cases. Escape names, messages and output, report skipped tests and cases, and capture test output so it appears with its test. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
rubytest -f html, so the HTML report no longer needs rubytest-html.Stacked on #13: this branch includes its commit, because both add an Unreleased section to
HISTORY.md. Merge #13 first; the diff here then shrinks to the second commit.Why a rewrite
rubytest-html 0.1.0 predates the recorder: it has no
recordorfinish, so rubytest 0.10 rejects it with "report format html does not support result reporting". It also wrote test names and messages into the page unescaped, put<li>elements outside any list, never reported skips, and signed itself "Lemon".What it does now
output:stream like the other bundled reporters, and follows the system's light or dark colour scheme.Testing
bundle exec rake test: 6 demos, 47 steps, 138 assertions, all passing on Ruby 3.4.9 and in aruby:2.7container. The new section indemo/05_builtin_reporters.mdchecks one result element per recorded result, balanced case sections, every status, and that markup in names and output is escaped.rubytest -f htmlon a file with a passing, failing, erroring, pending and skipped test inside and outside a case: the document's tags are balanced (checked with an HTML parser).🤖 Generated with Claude Code