]> Cypherpunks repositories - gostls13.git/commitdiff
unicode/utf8: remove init from utf8_test
authorLuka Krmpotic <luka.krmpotic@gmail.com>
Thu, 6 Feb 2025 21:33:18 +0000 (21:33 +0000)
committerGopher Robot <gobot@golang.org>
Thu, 6 Feb 2025 22:13:50 +0000 (14:13 -0800)
TestConstants and init test the same thing, remove init,
it does not exist in utf16_test.go either.

Fixes #71579

Change-Id: Ie0afd640bebde822733b6eac0bf98a17872f4e5f
GitHub-Last-Rev: d7224c18376e00038261279abdfa954abc3a8303
GitHub-Pull-Request: golang/go#71582
Reviewed-on: https://go-review.googlesource.com/c/go/+/647335
Commit-Queue: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Reviewed-by: Keith Randall <khr@google.com>
Reviewed-by: qiu laidongfeng2 <2645477756@qq.com>
Auto-Submit: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

src/unicode/utf8/utf8_test.go

index 69362d2cf1af6c7a8ef4cce315610dce15b36224..865167731f990be634a35b8e5aa435f34ee14749 100644 (file)
@@ -12,16 +12,6 @@ import (
        . "unicode/utf8"
 )
 
-// Validate the constants redefined from unicode.
-func init() {
-       if MaxRune != unicode.MaxRune {
-               panic("utf8.MaxRune is wrong")
-       }
-       if RuneError != unicode.ReplacementChar {
-               panic("utf8.RuneError is wrong")
-       }
-}
-
 // Validate the constants redefined from unicode.
 func TestConstants(t *testing.T) {
        if MaxRune != unicode.MaxRune {