Changes between Version 175 and Version 176 of j2p
- Timestamp:
- Dec 30, 2024, 12:09:35 PM (5 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
j2p
v175 v176 554 554 ||I get mockito.invocation.InvocationError: You tried to stub a method '__len__' the object (<class 'mockito.mocking.mock.<locals>.Dummy'>) doesn't have.||Python typing around the built-in types (list, set) is messy. If you stub a java List/Set, it translates to mock(typing.List/typing.Set). And those types do not have {{{___len___}}} causing the error. 555 555 In these special cases you need to use mock(list)/mock(set). Try manual translation of these types.|| 556 ||I'm getting {{{TypeError: missing a required argument}}} at runtime on an overloaded mockito mock call||python mockito and plum dispatch don't work together||It is easiest to work around the overloading. Change one of the overloaded method names.||