pampy
pampy copied to clipboard
Possibilty to match same object
Matching an instance of a class against it's class works perfectly but i just realied that you cannot match with the class itself:
class Marker: pass
match({"my_marker": Marker}, {"my_marker": Marker}, lambda x: print('MATCH'))
I think this should be a valid match right? Looking at the code at
https://github.com/santinic/pampy/blob/master/pampy/pampy.py#L59
seems like here we should add a check based on
inspect.isclass
What do you think?