Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^13: Introspecting function signatures

by LanX (Saint)
on Mar 07, 2021 at 21:31 UTC ( [id://11129299]=note: print w/replies, xml ) Need Help??


in reply to Re^12: Introspecting function signatures
in thread Introspecting function signatures

My take on it
  • if a test is called it should have fresh fixtures
  • you need to know which variables need to be initialized as fixtures
  • you need to know which tests use which fixtures
I think this can be done with a combination of PadWalker to scan the sub, and variable attributes to initialize them as fixture objects.

Unfortunately I'll be several days AFK, so I can't show you a POC.

Anyway I think you are rather inclined to do the PyWay and I've probably missed some edge cases.

(Tho you already mentioned py-decorators, and that's attributes in Perl.)

Feel free to ignore my thoughts and do as you like ...

Hope this helped nonetheless... :)

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery

  • Comment on Re^13: Introspecting function signatures

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11129299]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (3)
As of 2025-03-17 02:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    When you first encountered Perl, which feature amazed you the most?










    Results (54 votes). Check out past polls.