From b3ce6a356e5aebf797118325792d0410cca08caa Mon Sep 17 00:00:00 2001 From: "Bryan C. Mills" Date: Tue, 23 Jan 2024 15:34:02 -0500 Subject: [PATCH] windows: build env_windows_test.go only go Go 1.21 and above This test imports the "slices" package, which did not exist in Go 1.20. The test passes on Go 1.21 and above, and the behavior of the function under test is unlikely to vary by platform, so it doesn't seem worth refactoring the test to work with older releases. Updates golang/go#65055. Fixes golang/go#65223. Change-Id: I5f32106d6057b779579a87750633bc57f97fe152 Cq-Include-Trybots: luci.golang.try:x_sys-go1.20-windows-386,x_sys-go1.20-windows-amd64-longtest Reviewed-on: https://go-review.googlesource.com/c/sys/+/557975 Auto-Submit: Bryan Mills Reviewed-by: Cherry Mui LUCI-TryBot-Result: Go LUCI --- windows/env_windows_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/windows/env_windows_test.go b/windows/env_windows_test.go index 6824e6ed6..db1860e78 100644 --- a/windows/env_windows_test.go +++ b/windows/env_windows_test.go @@ -2,6 +2,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build go1.21 + package windows_test import (