{"categories":[{"label":"Testing","url":"https://skillfed.io/packages/category/software-development-testing/6"}],"enrichment":{"capability":"Decorator and context manager to mock Python's uuid module, returning fixed or sequenced UUIDs in tests instead of generating random ones.","skillfed_tags":["testing","mocking","uuid"],"use_cases":["Write deterministic unit tests for code that generates or uses UUIDs without relying on random values.","Test database operations where UUID primary keys must match expected values across test runs.","Verify UUID handling in async functions using pytest with parametrized test cases.","Mock UUID generation in libraries that build on the standard uuid module.","Create reproducible integration tests where UUID sequences need to be predictable."],"what_it_does":"freeze-uuid is a testing utility that replaces Python's uuid module with a mock that returns fixed or sequenced UUID values. It works as a decorator on test functions or as a context manager, allowing you to control exactly what UUIDs are generated during test execution. This eliminates randomness in tests that depend on UUID generation, making them deterministic and reproducible.\n\nThe package supports single fixed UUIDs, default zero-filled UUIDs, lists of sequential UUIDs, and async test functions. It mocks the underlying uuid.UUID class, so it works with any library that generates UUIDs through the standard module. With zero runtime dependencies and a pure-Python wheel, it installs with minimal friction.","worth_installing":"Yes, if you write tests for code that generates UUIDs and need deterministic behavior. The package is lightweight, has no dependencies, and solves a real testing problem. However, maintenance is dormant, so it will not receive bug fixes or updates\u2014acceptable for a stable, narrow-scope utility but worth noting if you need ongoing support."},"id":"freeze-uuid","links":{"html":"https://skillfed.io/packages/freeze-uuid","md":"https://skillfed.io/packages/freeze-uuid.md","pypi":"https://pypi.org/project/freeze-uuid/"},"maintenance":{"status":"dormant"},"meta":{"latest_release":"2024-05-04","license_spdx":null,"license_treatment":"permissive","name":"freeze-uuid","python_support":"supports_current","summary":"Python package for mocking uuid."},"popularity":{"monthly_downloads":106021,"position":12671,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"0.4.3"}
