update stuff
This commit is contained in:
19
id_test.go
Normal file
19
id_test.go
Normal file
@@ -0,0 +1,19 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestIdGeneration(t *testing.T) {
|
||||
// Generate a random ID
|
||||
id := NewCartId()
|
||||
|
||||
// Generate a random ID
|
||||
id2 := NewCartId()
|
||||
// Compare the two IDs
|
||||
if id == id2 {
|
||||
t.Errorf("IDs are the same: %v == %v", id, id2)
|
||||
} else {
|
||||
t.Log("ID generation test passed", id, id2)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user