https://pantsbuild.org/ logo
#development
Title
# development
b

bitter-ability-32190

09/05/2022, 1:31 AM
I don't understand
run_rule_with_mocks
enough. I have 2 field sets i"m testing with
run_test
. If I omit the
MockGet(RunRequest, SecondFieldSetType)
it runs but complains about not being able to satisfy the request. If I add it I get
ValueError
about the
Get
providers. Not sure what I'm doing wrong.
e

enough-analyst-54434

09/05/2022, 1:37 AM
Is your example intended to be accurate? It has no 3rd argument - the actual mock callable: https://github.com/pantsbuild/pants/blob/2168bb3b0a5074e4f69644fa78df60f4ed3098be/src/python/pants/testutil/rule_runner.py#L522-L528
b

bitter-ability-32190

09/05/2022, 1:38 AM
Ahhhhh found it, looks like the previous authors were lazy and left off
union_membership