I added a stub to the `pear` module: <https://gith...
# request-review
n
I added a stub to the
pear
module: https://github.com/nf-core/modules/pull/9023
👀 1
Thanks @Maxime Garcia I think I fixed everything 😛
m
I like your approach with
Copy code
assert snapshot(process.out.collectEntries { key, val ->
                if (key[0].isNumber()) {
                    // Skip numbered outputs
                    return
                }
                if (key == "discarded") {
                    // Discarded fastq is empty, causing a lint failure => only check filename for this output
                    return [key, val.collect { meta, fastq -> [ meta, file(fastq).name ]}]
                } else if (key == "versions") {
                    return [key, val.collect { file -> path(file).yaml }]
                } else {
                    return [key, val]
                }
            } ).match()
that works with current lint?
I'm impressed
n
yes 😛 I've used it a couple of times to create clean snapshots 😛 while still outputting everything that the module produces
m
we need to put that upstream
n
I'm thinking of adding a helper function of this to
nft-utils
but I need to think on how to make this general enough for that
party this 1
m
🙏 pretty please 🙏
n
When I find some time for sure!
m
Have you tried asking AI for some ideas?
n
Not yet 😛
m
you know that nft-utils is AI assisted quite a lot
I removed lots of the extra thing done by AI, and rewrote the tests that were terrible
but it worked quite nicely
n
Yeah it works pretty well! 😛 I'll give it a go later 😉