Tags: jaswdr/faker
Tags
Fix: Generate deterministic string data when using seeded Faker insta… …nces (#216) * Initial plan * Initial exploration: Identified UUID.V4() using crypto/rand as root cause Co-authored-by: jaswdr <[email protected]> * Fix UUID.V4() to use seeded random generator for deterministic string generation Co-authored-by: jaswdr <[email protected]> * Add UUID format validation test to ensure proper v4 UUID structure Co-authored-by: jaswdr <[email protected]> * Move determinism tests from determinism_test.go to uuid_test.go Co-authored-by: jaswdr <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: jaswdr <[email protected]>
Codebase improvements (#203) * Fix RandomDigitNot function comparing array index instead of value * Create single generateFloat helper function * Optimize string building template for Numerify, Lexify and Bothify functions * Simplify between function logic for better readability * Simplify IPv6 generation logic in internet.go using string builder * Fix infinite recursion risk in utils.go Shuffle function * Optimize RandomElementWeighted to avoid temporary array creation * Optimize address.go template processing with pre-compiled templates * Add benchmark tests for performance-critical functions * style: format code with Go fmt and Gofumpt This commit fixes the style issues introduced in e2a29e4 according to the output from Go fmt and Gofumpt. Details: #203 * Fix usage of minN parameter * Ignore CLAUDE.local.md * Fix unused variable * Reduce number of architectures to run tests agains't * Replace www.example.com with www.google.com * Create initial Claude agents * Apply multiple improvements * Delete Github actions * Fix static analysis violations * Remove unused parameter in test functions --------- Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com>
fix: support 32-bit architectures (#198) * ci: add tests for 386, arm and riscv64 * fix: support 32-bit architectures * fix(ci): bump go version to 1.22 * style: use old function names for backwards compatability * style: min, max -> minN, maxN * style: remove redundant type in variable declaration
refactor: Remove redundant float rounding checks in tests (#195) * refactor: Remove redundant float rounding checks in tests - Eliminated unnecessary rounding assertions in TestRandomFloat, TestFloat, TestFloat32, and TestFloat64 to streamline test logic and improve clarity. * ci: retry unit tests 3 times
feat: Enhance struct filling with recursive support and depth control (… …#185) - Added FillWithDepth method to allow specifying maximum recursion depth for nested structs. - Improved fillValue method to handle recursive structures and nested arrays. - Updated tests to cover new functionality, including child structures and nested arrays with fakesize. - Enhanced existing tests for clarity and coverage of various struct types.
PreviousNext