LEFT | RIGHT |
(no file at all) | |
1 // Copyright 2011 The Go Authors. All rights reserved. | 1 // Copyright 2011 The Go Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style | 2 // Use of this source code is governed by a BSD-style |
3 // license that can be found in the LICENSE file. | 3 // license that can be found in the LICENSE file. |
4 | 4 |
5 package build | 5 package build |
6 | 6 |
7 import ( | 7 import ( |
8 "runtime" | 8 "runtime" |
9 "testing" | 9 "testing" |
10 ) | 10 ) |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 {"file_" + thisOS + "_" + otherArch + ".go", false}, | 48 {"file_" + thisOS + "_" + otherArch + ".go", false}, |
49 {"file_" + otherOS + "_" + otherArch + ".go", false}, | 49 {"file_" + otherOS + "_" + otherArch + ".go", false}, |
50 {"file_foo_" + thisArch + ".go", true}, | 50 {"file_foo_" + thisArch + ".go", true}, |
51 {"file_foo_" + otherArch + ".go", false}, | 51 {"file_foo_" + otherArch + ".go", false}, |
52 {"file_" + thisOS + ".c", true}, | 52 {"file_" + thisOS + ".c", true}, |
53 {"file_" + otherOS + ".c", false}, | 53 {"file_" + otherOS + ".c", false}, |
54 } | 54 } |
55 | 55 |
56 func TestGoodOSArch(t *testing.T) { | 56 func TestGoodOSArch(t *testing.T) { |
57 for _, test := range tests { | 57 for _, test := range tests { |
58 » » if DefaultContext.goodOSArch(test.name) != test.result { | 58 » » if DefaultContext.goodOSArchFile(test.name) != test.result { |
59 » » » t.Fatalf("goodOSArch(%q) != %v", test.name, test.result) | 59 » » » t.Fatalf("goodOSArchFile(%q) != %v", test.name, test.res
ult) |
60 } | 60 } |
61 } | 61 } |
62 } | 62 } |
LEFT | RIGHT |