🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). Log available at irclogs.raku.org/raku/live.html . If you're a beginner, you can also check out the #raku-beginner channel!
Set by lizmat on 6 September 2022.
tbrowder__ how can we get tadzik's File::Find module repo transferred to the community repo? he is willing, just need the instructions 11:12
lizmat tbrowder__ left some instructions in a privmsg to tadzik 11:22
aryan i 11:26
hi
lizmat aryan o/ 11:27
tbrowder__ thnx 11:56
tbrowder__ so, a testing question: a module has a bin file that takes another bin file as input and creates another bin file as output. using the Test module, how can i assure that works (not correctness of the output, just that it exists and is named as expected. a flow something like this: myprog myinfile => myoutfile. 12:01
tbrowder__ i've tried using Proc::Easier and lives-ok but output seems to hide somewhere 12:03
moritz_ uhm, what is your question? how to check if a file exists? 12:07
tbrowder__ i've looked at jmerelo's test module but don't see it quite fits the bill. hm, a blinking light of an idea appeared...it should work. like test helpers in roast. bye
moritz_ not everything that's done in a test needs to be done by a test module, you can write normal code and just check its result, y'know :-) 12:09
tbrowder__ moritz, yes, essentially i just did that, i was trying to test a bin file. i changed to testing the generating subs, that worked. 12:32
but your way is better, thnx 12:33
but, how would you do that testing with github workflows? 12:35
for my brain muscle memory, using the subs might be easier 12:36
ugexe create a CI test that runs the various commands of your bin script: `bin/my-prog thing1`, `bin/my-prog thing2`. and if you put all the business logic inside of modules and just have the bin script invoke those, you can test your business logic by testing your module 12:54
for example github.com/ugexe/zef/blob/710034fe...ml#L29-L39 12:55
xinming_ releasable6: status 13:07
releasable6 xinming_, Next release will happen when it's ready. There are no known blockers. 0 out of 64 commits logged (⚠ 167 warnings)
xinming_, Details: gist.github.com/939ece1e5407c15950...68d26794c5
tbrowder_ ugexe: thanks 13:25
gfldex m: say Any."WHAT"(); 16:44
camelia No such method 'WHAT' for invocant of type 'Any'. Did you mean any of
these: 'WHAT', 'WHO', 'WHY', 'flat'?
in block <unit> at <tmp> line 1
gfldex :->
lizmat m: say Any.^find_method("WHAT") 16:46
camelia (Mu)
lizmat m: say Any.^find_method("Int") 16:47
camelia Int
lizmat m: dd Any.^find_method("Int")
camelia Method Int = proto method Int (Mu: |) {*}
lizmat m: dd Any.^find_method("WHAT")
camelia Mu
lizmat that's macros for you :-) 16:48
gfldex What I find surprising is that Rakudo suggests `'WHAT', ...`. How does it know about a method that isn't there? 17:15
lizmat he, good question 17:18
m: say Any.^methods.map(*.name).sort # it's not in here 17:19
camelia (ACCEPTS ASSIGN-KEY ASSIGN-POS AT-KEY AT-POS Array BIND-KEY BIND-POS Bag BagHash DELETE-KEY DELETE-POS EXISTS-KEY EXISTS-POS FLATTENABLE_HASH FLATTENABLE_LIST Hash List Map Mix MixHash Seq Set SetHash Slip Supply ZEN-KEY all antipairs any append are b…
[Coke] I assume a special case in the suggest logic?
(though a quick search didn't find it)
gfldex Would Rakudo tell us it it would become self-aware? :D 17:20
MasterDuke github.com/rakudo/rakudo/blob/main...#L285-L288  # [Coke], gfldex fyi 17:55
lizmat I guess we need a check that the suggestion doesn't match the unfound method :-) 18:03
antononcube @lizmat I just upvoted your criticism of "kebabtize". 🙂 18:40
librasteve I put this line in my Dockerfile RUN zef install github.com/librasteve/raku-physics-measure.git --verbose 18:51
and then run a standard GHA like the workflows here github.com/librasteve/raku-Physics.../tree/main
even better if you have a module with Build.pm then the zef install will run build and test 18:52
(there are likely a lot better ways from others on this chat!) 18:54
tbrowder__ lizmat: The Rakudo Star manager is interested in a #raku-star channel. is that possible? 19:06
lizmat tbrowder__ Most definitely... will set it up tomorrow 22:10
SmokeMachine tonyo: github.com/FCO/Test-Fuzz 23:10
antononcube @SmokeMachine So, nothing stops us to generate Fuzz-tests with LLMs then. (In Raku.) 23:14
I currently experimenting generating Gherkin tests with LLMs. I will try "Test:Fuzz" soon. 23:16
SmokeMachine Yes, I don’t think anything does… but I still need to improve the generator API for test::fuzz
If I remember it well, it needs a class method to generate objects from that class… but it would be much better to just need to implement a multi sub “test-sames-generator” to do that 23:18
tbrowder__ lizmat: thanks 23:28
antononcube @SmokeMachine Ok, good to keep in mind. 23:32