ratmice / nimbleparse_lsp

lsp server for grmtools lex & yacc
Other
7 stars 1 forks source link

Toml TestDir #17

Closed ratmice closed 2 years ago

ratmice commented 2 years ago

It's become quickly apparent that the

[[tests]]
dir = "foo/"

Isn't flexible enough for some projects, where you'd want dir = "foo/**, part of this is you want to be able to selectively enable/disable globbing, so it shouldn't just do a recursive walk over dir = "foo/",

A case where this is important is when you have dir = "fail/parser" and succeed/**, and you shouldn't assume that fail/** wouldn't lead to a successful parse fail/** may often parse but contain logical errors.

Unfortunately the way we initially exported it is as a pub dir: toml::Spanned<PathBuf>,, but the toml library shouldn't really be doing globbing so this should probably be a String. While we're at it we should consider things like test generators so we can add things in the future so it should probably be similar to the way we serialize YaccKind.