Closed Nenuial closed 3 months ago
I'll have a look at it later today. I'm quite unfamiliar with tests, but I'm up for the challenge.
No hurry! And I'm happy to answer questions. :smile_cat:
Regarding the basics of tests I recommend reading the three chapters on testing in https://r-pkgs.org/testing-basics.html (but then you might have meant you were not familiar with babelquarto tests, and I won't pretend they 100% follow best practice :sweat_smile: )
I've added two tests. The first one checks if a listing only includes the one page it should have. The second tests looks at the files that exist (or shouldn't exist) depending on the languages that exist for a given file.
Thank you for your guidance!
Based on the discussion in #58, here's my PR with just the recurse part. This fixes all my problems with listings and doesn't copy files from other languages if they aren't present.
I've also made a change that avoids adding a translation link to a non existing page (creating 404s when a page only exists in one language).