Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parameterize and flesh out test_caches #199

Open
masklinn opened this issue Mar 2, 2024 · 0 comments
Open

Parameterize and flesh out test_caches #199

masklinn opened this issue Mar 2, 2024 · 0 comments
Milestone

Comments

@masklinn
Copy link
Contributor

masklinn commented Mar 2, 2024

#197 removed the caches from test_core, because they added several seconds per cache per run, for basically no value: unless the cache is completely broken, the yaml tests from uap-core only have singletons so the caches didn't do anything.

What would be more useful is having test_caches do a lot more interesting generic stuff (e.g. test cache hits within the cache's size to ensure caches don't overclear — or underclear for that matter) stuff like that.

Notably missing tests:

@masklinn masklinn added this to the 1.0 milestone Mar 2, 2024
@masklinn masklinn changed the title Remove caches from test_core, parameterize and flesh out test_caches Parameterize and flesh out test_caches Mar 12, 2024
masklinn added a commit to masklinn/uap-python that referenced this issue Mar 28, 2024
Partial results are back-filled (new domains added) by re-setting them
in the cache. With a sufficiently incorrect implementation, the cache
can evict entries on that occasion even though it does not need
to (because we're replacing an existing entry).

Exactly that should have been fixed by ua-parser#204, but was not tested at the
time.

Fixes ua-parser#199
masklinn added a commit to masklinn/uap-python that referenced this issue Mar 30, 2024
Partial results are back-filled (new domains added) by re-setting them
in the cache. With a sufficiently incorrect implementation, the cache
can evict entries on that occasion even though it does not need
to (because we're replacing an existing entry).

Exactly that should have been fixed by ua-parser#204, but was not tested at the
time.

Fixes ua-parser#199
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant