File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -80,24 +80,34 @@ func TestImportTypeparamTests(t *testing.T) {
80
80
t .Skip ("unified export data format is currently unsupported" )
81
81
}
82
82
83
+ skip := map [string ]string {
84
+ "issue48424.go" : "go/types support missing" , // TODO: need to implement this if #48424 is accepted
85
+ }
86
+
83
87
for _ , entry := range list {
84
88
if entry .IsDir () || ! strings .HasSuffix (entry .Name (), ".go" ) {
85
89
// For now, only consider standalone go files.
86
90
continue
87
91
}
88
92
89
93
t .Run (entry .Name (), func (t * testing.T ) {
94
+ if reason , ok := skip [entry .Name ()]; ok {
95
+ t .Skip (reason )
96
+ }
97
+
90
98
filename := filepath .Join (rootDir , entry .Name ())
91
99
src , err := os .ReadFile (filename )
92
100
if err != nil {
93
101
t .Fatal (err )
94
102
}
103
+
95
104
if ! bytes .HasPrefix (src , []byte ("// run" )) && ! bytes .HasPrefix (src , []byte ("// compile" )) {
96
105
// We're bypassing the logic of run.go here, so be conservative about
97
106
// the files we consider in an attempt to make this test more robust to
98
107
// changes in test/typeparams.
99
108
t .Skipf ("not detected as a run test" )
100
109
}
110
+
101
111
testExportSrc (t , src )
102
112
})
103
113
}
You can’t perform that action at this time.
0 commit comments