<@UKPS08ZGW>: so, i think that `def rules(self)` o...
# development
w
@hundreds-breakfast-49010: so, i think that
def rules(self)
on testbase is not doing the thing that our actual registrar does
@hundreds-breakfast-49010: ^
options parsing is based on gathering up all of the "Optionable" things
so you might need to fiddle with TestBase a bit to do that... sorry =(
. @happy-kitchen-89482 is very likely to know how to help there though!
h
kk
hm this is a bit rabbit-hole-ish
I just need a way to get a string from the test method into the
@console_rule
I thought an option would be an easy way to make that happen but apparently not
is there some other solution I'm missing to this?
w
Um, maybe capture the rules stdout?
h
I need the other direction, the test needs to provide a string to the @console_rule
w
A param?
Whoops. Didn't mean to send to channel
But in an isolated context like this, you could install a RootRule for
str
And pass in a
str
when running the rule
And you could wrap it in a newtype if the
str
gives you trouble
(maybe
ConsoleRuleTestBase
doesn't let you pass other args to be used as params... But that would be easy to add)
h
@witty-crayon-22786 just spend some time digging into this with benjy
he pointed out that in
ConsoleRuleTestBase
we are creating
full_options
there, which has the correct options scope, but then not passing it to
run_console_rule
so maybe this is the bug
I think it would solve my problem at hand more quickly if I just hacked in the ability to pass an additional newtype'd string Param in the test
but this is maybe a bug in the test code worth solving
w
Yeah, I think both changes would be great. Up to you
h
I'm gonna make an issue for this but punt on it for now
unless the newtype thing doesn't work for whatever reason