Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: cover
SopelMemoryWithDefault.__contains__()
Since the whole point of this type is to have a thread-safe version of `collections.defaultdict` and not have to check for `'key' in SMWD` before accessing something, the `__contains__()` method (supporting the `in` keyword) is never exercised in regular code. The rest of `SopelMemoryWithDefault` is covered by other test cases for code that *uses* the type, so I'll just keep this patch small. Now the only uncovered code in `sopel/tools/memories.py` is for variadic argument handling that we plan to remove anyway, so 98% is fine for now.
- Loading branch information