From a6e6896309007fa1013bd51cee125ab8a75f282d Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Sat, 3 May 2025 19:41:19 -0300 Subject: re s/guuid/uuid/g --- tests/benchmarks/string-roundtrip/guuid.go | 37 ------------------------------ tests/benchmarks/string-roundtrip/uuid.go | 37 ++++++++++++++++++++++++++++++ 2 files changed, 37 insertions(+), 37 deletions(-) delete mode 100644 tests/benchmarks/string-roundtrip/guuid.go create mode 100644 tests/benchmarks/string-roundtrip/uuid.go (limited to 'tests/benchmarks/string-roundtrip') diff --git a/tests/benchmarks/string-roundtrip/guuid.go b/tests/benchmarks/string-roundtrip/guuid.go deleted file mode 100644 index 9fef55c..0000000 --- a/tests/benchmarks/string-roundtrip/guuid.go +++ /dev/null @@ -1,37 +0,0 @@ -package guuid - -import ( - "flag" - "fmt" -) - - - -var nFlag = flag.Int( - "n", - 10_000_000, - "The number of iterations to execute", -) - -func MainTest() { - flag.Parse() - n := *nFlag - - uuid := New() - - for i := 0; i < n; i++ { - derived, err := FromString(uuid.String()) - if err != nil { - panic(err) - } - - eq := uuid == derived - if !eq { - panic(fmt.Sprintf( - "bad round trip: orig (%#v); derived (%#v)", - uuid, - derived, - )) - } - } -} diff --git a/tests/benchmarks/string-roundtrip/uuid.go b/tests/benchmarks/string-roundtrip/uuid.go new file mode 100644 index 0000000..d686e04 --- /dev/null +++ b/tests/benchmarks/string-roundtrip/uuid.go @@ -0,0 +1,37 @@ +package uuid + +import ( + "flag" + "fmt" +) + + + +var nFlag = flag.Int( + "n", + 10_000_000, + "The number of iterations to execute", +) + +func MainTest() { + flag.Parse() + n := *nFlag + + uuid := New() + + for i := 0; i < n; i++ { + derived, err := FromString(uuid.String()) + if err != nil { + panic(err) + } + + eq := uuid == derived + if !eq { + panic(fmt.Sprintf( + "bad round trip: orig (%#v); derived (%#v)", + uuid, + derived, + )) + } + } +} -- cgit v1.2.3