Class: Ucode::Audit::Formatters::AuditDiffText
- Inherits:
-
Object
- Object
- Ucode::Audit::Formatters::AuditDiffText
- Defined in:
- lib/ucode/audit/formatters/audit_diff_text.rb
Overview
Human-readable diff of two Models::Audit::AuditReports.
Output groups changes by kind: scalar field changes, codepoint set deltas (added/removed counts and a preview of the ranges), then structural inventory changes (scripts, features, blocks). Empty sections are omitted so a no-op diff prints only the header and a "(no differences)" footer.
ucode delta vs fontisan's AuditDiffTextRenderer: drops the LANGUAGES section (CLDR is out of scope).
Constant Summary collapse
- SEPARATOR =
"=" * 80
- LIST_LIMIT =
10
Instance Method Summary collapse
-
#initialize(diff) ⇒ AuditDiffText
constructor
A new instance of AuditDiffText.
- #render ⇒ String
Constructor Details
#initialize(diff) ⇒ AuditDiffText
Returns a new instance of AuditDiffText.
21 22 23 24 25 |
# File 'lib/ucode/audit/formatters/audit_diff_text.rb', line 21 def initialize(diff) @diff = diff @lines = [] @helper = TextFormatter.new end |
Instance Method Details
#render ⇒ String
28 29 30 31 32 33 34 35 |
# File 'lib/ucode/audit/formatters/audit_diff_text.rb', line 28 def render render_header render_field_changes render_codepoint_delta render_structural_changes render_empty_note @lines.join("\n") end |