src/crypto/internal/cryptotest/fips140.go
raw| 1 | // Copyright 2025 The Go Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style |
| 3 | // license that can be found in the LICENSE file. |
| 4 | |
| 5 | package cryptotest |
| 6 | |
| 7 | import ( |
| 8 | "crypto/internal/fips140" |
| 9 | "testing" |
| 10 | ) |
| 11 | |
| 12 | func MustSupportFIPS140(t *testing.T) { |
| 13 | t.Helper() |
| 14 | if err := fips140.Supported(); err != nil { |
| 15 | t.Skipf("test requires FIPS 140 mode: %v", err) |
| 16 | } |
| 17 | } |