devel is now up to date with the beauty branch. Today's work accomplishes the following:
1. Fixed several bugs in the essential SyntaxSanitizer class.
2. Created the "@test SyntaxSanitizer" unit test in unitTest.leo. This is a strong test, and tests the SyntaxSanitizer class and the beautify and blacken commands.
3. Protected four methods, including g.angleBrackets(!), from being blackened. Formerly, these methods relied on "<<" and ">>" being on different lines, so as to avoid a spurious section reference. But black can put them back on the same line. Now, lt and rt are defined (on separate lines) as "<<" and ">>". It's fine to put lt and rt on the same line.
4. With all these fixes, running blacken-tree on the "Core classes" node in leoPy.leo succeeds without serious problems. Saving the outline then updates all the files. All unit tests still pass.
Summary
The blacken commands now passes substantial tests. There are no known bugs. Imo, these commands are ready for serious testing.
However, I do not plan to blacken Leo's sources at this time. I don't believe it would be particularly useful to do so, and I don't want to spend the required time looking at diffs.
I shall now turn my attention to the "orange is the new black" project. Imo, improving Leo's beautify commands will be more useful for most Leonistas. There surely will be more options to choose from :-)
Edward