Repository navigation
test: Check the hyphenation the specs expect - #46
Open
henrikottesorensen wants to merge 2 commits into
Open
henrikottesorensen wants to merge 2 commits into
henrikottesorensen wants to merge 2 commits into
Conversation
The eight dictionary harnesses are 60MB and 1,953,878 cases between them, about two minutes against the spec suite's twenty seconds. They all pass against 3.40.0, so leaving them out of LibLouis.NET.Test cost the tables' word lists rather than hiding a failure, but nothing ran them. LibLouis.NET.DictionaryTest runs them. It reads them from the release build/stage_tables.sh already downloads rather than from a committed copy, so the repository does not grow by 60MB and they follow LiblouisVersion with nothing to re-copy. They are listed one by one: a wildcard on "dictionary" also matches nine ordinary specs LibLouis.NET.Test already runs. The build fails, naming stage_tables.sh, if they have not been staged, rather than discovering no tests. The harness moves out of BrailleSpecTests into BrailleSpecRunner so both projects compile the same one. The code moves unchanged. CI runs them in a dictionary-test job on the same three operating systems as test, beside it rather than after it, so pull requests wait no longer and a failure among them is reported apart from the main suite. publish waits for it too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2,292 spec entries were dropped as testmode: hyphenate, all of them in hu-hu-g1-hyph_harness.yaml. They are now run: the word goes through the wrapper's Hyphenate with the translation table alone, as lou_checkyaml does (lou_checkyaml.c:905-909), and is written out the way check_hyphenation does (brl_checks.c): a '-' before every character flagged as a break point, '|' for a '2'. A first flag other than '0' is a failure, as it is there. hyphenateBraille is driven the same way with lou_hyphenate's braille mode, though no spec uses it yet. All 2,292 pass. Writing '=' instead of '-' fails 2,251 of them; the other 41 are words with no break point. lou_checkyaml ignores what check_hyphenation returns, so upstream prints a hyphenation mismatch and passes anyway. Here one fails like any other case, which is stricter than upstream, and it turns out to cost nothing: none of the 2,292 disagrees. The tally loses testmode: hyphenate (2292). display is now the only testmode still skipped. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Built on #44. Until #44 merges, this PR also shows its commit (128b26e); the change here is the top commit only.
Stops skipping the 2,292
testmode: hyphenateentries, all inhu-hu-g1-hyph_harness.yaml. All of them pass.What changed
hyphenateandhyphenateBraillebecome real test modes instead of skipped ones.displayis now the only testmode still skipped.Hyphenate, with the translation table alone, aslou_checkyaml.c:905-909does. The result is written out the waycheck_hyphenationdoes inbrl_checks.c:-before every character flagged as a break point,|for a2. A first flag other than0is a failure, as it is there.hyphenateBrailleuseslou_hyphenate's braille mode, though no spec uses it yet.testmode: hyphenate(2292) is gone.Stricter than upstream
lou_checkyamlignores whatcheck_hyphenationreturns, so upstream prints a hyphenation mismatch to stderr and passes anyway. Here a mismatch fails like any other case. That costs nothing today, because none of the 2,292 disagrees.Testing
On macOS arm64:
LibLouis.NET.Testpasses 237/237, and the solution builds with-warnaserror.=instead of-failed 2,251 of the 2,292 cases; the other 41 are words with no break point.Overlap with #45
Both PRs change the reader's case-building code in
BrailleSpec.csandRuninBrailleSpecRunner.cs, so whichever merges second needs a rebase there; the tally merges cleanly. I can do that rebase once the first one lands.🤖 Generated with Claude Code