*: remove checks for TRAVIS env variable (#3568)
We had a few checks left over for the TRAVIS variable that detected if we were running under the TravisCI build system. This variable hasn't been set since 2020.
This commit is contained in:
parent
938cb6e9d8
commit
a8ee87e473
@ -130,7 +130,7 @@ This option can only be specified if testset is basic or a single package.`)
|
||||
|
||||
func checkCert() bool {
|
||||
// If we're on OSX make sure the proper CERT env var is set.
|
||||
if os.Getenv("TRAVIS") == "true" || runtime.GOOS != "darwin" || os.Getenv("CERT") != "" {
|
||||
if runtime.GOOS != "darwin" || os.Getenv("CERT") != "" {
|
||||
return true
|
||||
}
|
||||
|
||||
@ -328,9 +328,6 @@ func testFlags() []string {
|
||||
}
|
||||
if NOTimeout {
|
||||
testFlags = append(testFlags, "-timeout", "0")
|
||||
} else if os.Getenv("TRAVIS") == "true" {
|
||||
// Make test timeout shorter than Travis' own timeout so that Go can report which test hangs.
|
||||
testFlags = append(testFlags, "-timeout", "9m")
|
||||
}
|
||||
if len(os.Getenv("TEAMCITY_VERSION")) > 0 {
|
||||
testFlags = append(testFlags, "-json")
|
||||
@ -344,20 +341,6 @@ func testFlags() []string {
|
||||
func testCmd(cmd *cobra.Command, args []string) {
|
||||
checkCertCmd(nil, nil)
|
||||
|
||||
if os.Getenv("TRAVIS") == "true" && runtime.GOOS == "darwin" {
|
||||
fmt.Println("Building with native backend")
|
||||
execute("go", "build", "-tags=macnative", buildFlags(), DelveMainPackagePath)
|
||||
|
||||
fmt.Println("\nBuilding without native backend")
|
||||
execute("go", "build", buildFlags(), DelveMainPackagePath)
|
||||
|
||||
fmt.Println("\nTesting")
|
||||
os.Setenv("PROCTEST", "lldb")
|
||||
env := []string{}
|
||||
executeq(env, "sudo", "-E", "go", "test", testFlags(), allPackages())
|
||||
return
|
||||
}
|
||||
|
||||
if TestSet == "" && TestBackend == "" && TestBuildMode == "" {
|
||||
if TestRegex != "" {
|
||||
fmt.Printf("Can not use --test-run without --test-set\n")
|
||||
|
@ -366,9 +366,6 @@ func diffMaybe(t *testing.T, filename string, generated []byte) {
|
||||
// TestGeneratedDoc tests that the autogenerated documentation has been
|
||||
// updated.
|
||||
func TestGeneratedDoc(t *testing.T) {
|
||||
if strings.ToLower(os.Getenv("TRAVIS")) == "true" && runtime.GOOS == "windows" {
|
||||
t.Skip("skipping test on Windows in CI")
|
||||
}
|
||||
if runtime.GOOS == "windows" && runtime.GOARCH == "arm64" {
|
||||
//TODO(qmuntal): investigate further when the Windows ARM64 backend is more stable.
|
||||
t.Skip("skipping test on Windows in CI")
|
||||
|
@ -3054,11 +3054,6 @@ func TestIssue877(t *testing.T) {
|
||||
if runtime.GOOS != "darwin" && testBackend == "lldb" {
|
||||
return
|
||||
}
|
||||
if os.Getenv("TRAVIS") == "true" && runtime.GOOS == "darwin" {
|
||||
// Something changed on Travis side that makes the Go compiler fail if
|
||||
// DYLD_LIBRARY_PATH is set.
|
||||
t.Skip("broken")
|
||||
}
|
||||
const envval = "/usr/local/lib"
|
||||
t.Setenv("DYLD_LIBRARY_PATH", envval)
|
||||
withTestProcess("issue877", t, func(p *proc.Target, grp *proc.TargetGroup, fixture protest.Fixture) {
|
||||
|
@ -307,9 +307,6 @@ func MustSupportFunctionCalls(t *testing.T, testBackend string) {
|
||||
t.Skip("this backend does not support function calls")
|
||||
}
|
||||
|
||||
if runtime.GOOS == "darwin" && os.Getenv("TRAVIS") == "true" && runtime.GOARCH == "amd64" {
|
||||
t.Skip("function call injection tests are failing on macOS on Travis-CI (see #1802)")
|
||||
}
|
||||
if runtime.GOARCH == "386" {
|
||||
t.Skip(fmt.Errorf("%s does not support FunctionCall for now", runtime.GOARCH))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user