Debian Codegraph @

go/analysis/passes/asmdecl/asmdecl_test.go

raw symbols SCIP
1 // Copyright 2018 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 asmdecl_testscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/passes/asmdecl_test`/
6
7 import (
8 "osscip-go gomod github.com/golang/go/src go1.25.0 os/"
9 "stringsscip-go gomod github.com/golang/go/src go1.25.0 strings/"
10 "testingscip-go gomod github.com/golang/go/src go1.25.0 testing/"
11
12 "golang.org/x/tools/go/analysis/analysistestscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/analysistest`/"
13 "golang.org/x/tools/go/analysis/passes/asmdeclscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/passes/asmdecl`/"
14 )
15
16 var goosarchesscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/passes/asmdecl_test`/goosarches. = []string{
17 "linux/amd64", // asm1.s, asm4.s
18 "linux/386", // asm2.s
19 "linux/arm", // asm3.s
20 // TODO: skip test on loong64 until go toolchain supported loong64.
21 // "linux/loong64", // asm10.s
22 "linux/mips64", // asm5.s
23 "linux/s390x", // asm6.s
24 "linux/ppc64", // asm7.s
25 "linux/mips", // asm8.s,
26 "js/wasm", // asm9.s
27 "linux/riscv64", // asm11.s
28 }
29
30 func Testscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/passes/asmdecl_test`/Test().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
31 testdata := analysistestscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/analysistest`/.TestDatascip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/analysistest`/TestData.()
32 for _, goosarch := range goosarchesscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/passes/asmdecl_test`/goosarches. {
33 t.Runscip-go gomod github.com/golang/go/src go1.25.0 testing/T#Run().(goosarch, func(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
34 i := stringsscip-go gomod github.com/golang/go/src go1.25.0 strings/.Indexscip-go gomod github.com/golang/go/src go1.25.0 strings/Index().(goosarch, "/")
35 osscip-go gomod github.com/golang/go/src go1.25.0 os/.Setenvscip-go gomod github.com/golang/go/src go1.25.0 os/Setenv().("GOOS", goosarch[:i])
36 osscip-go gomod github.com/golang/go/src go1.25.0 os/.Setenvscip-go gomod github.com/golang/go/src go1.25.0 os/Setenv().("GOARCH", goosarch[i+1:])
37 analysistestscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/analysistest`/.Runscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/analysistest`/Run().(t, testdata, asmdeclscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/passes/asmdecl`/.Analyzerscip-go gomod golang.org/x/tools . `golang.org/x/tools/go/analysis/passes/asmdecl`/Analyzer., "a")
38 })
39 }
40 }