Debian Codegraph @

gopls/internal/analysis/maprange/maprange_test.go

raw symbols SCIP
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 maprange_test
6
7 import (
8 "golang.org/x/tools/go/analysis/analysistest"
9 "golang.org/x/tools/gopls/internal/analysis/maprange"
10 "golang.org/x/tools/internal/testfiles"
11 "path/filepath"
12 "testing"
13 )
14
15 func TestBasic(t *testing.T) {
16 dir := testfiles.ExtractTxtarFileToTmp(t, filepath.Join(analysistest.TestData(), "basic.txtar"))
17 analysistest.RunWithSuggestedFixes(t, dir, maprange.Analyzer, "maprange")
18 }
19
20 func TestOld(t *testing.T) {
21 dir := testfiles.ExtractTxtarFileToTmp(t, filepath.Join(analysistest.TestData(), "old.txtar"))
22 analysistest.RunWithSuggestedFixes(t, dir, maprange.Analyzer, "maprange")
23 }