igneus / calendarium-romanum

liturgical calendar library (Roman Catholic, post-Vatican II)
50 stars 21 forks source link

Liturgical law specs: meaningful example names #101

Closed igneus closed 3 weeks ago

igneus commented 1 year ago

spec/liturgical_law_spec.rb builds specs from code examples contained in the markdown files in liturgical_law/. Example names contain markdown file paths and line numbers. 2023-06-06-233153_1366x768_scrot

It would be desirable to

So e.g. the example L525 would have a name like 36. Dominica a die 2... and be nested in several levels of example groups, the deepest one of them being IV. De tempore Nativitatis

igneus commented 3 weeks ago

Nested example groups mirroring chapter/section headings in the documents were not implemented, as RSpec refuses to work when example groups are dynamically generated in recursive method calls. (And most documents are short and contain just a few examples anyway.)