- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for Alphanumeric (0.3 sec)
-
cmd/api-headers_test.go
package cmd import ( "testing" ) func TestNewRequestID(t *testing.T) { // Ensure that it returns an alphanumeric result of length 16. id := mustGetRequestID(UTCNow()) if len(id) != 16 { t.Fail() } var e rune for _, char := range id { e = char // Ensure that it is alphanumeric, in this case, between 0-9 and A-Z. if !(('0' <= e && e <= '9') || ('A' <= e && e <= 'Z')) { t.Fail() } }
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Sun Jan 02 17:15:06 GMT 2022 - 1.1K bytes - Viewed (0)