service/test: Added test for issue #528
This issue is fixed by go 1.7, the test will only run on newer versions of the compiler.
This commit is contained in:
parent
60eabf045b
commit
a1ac17f16c
12
_fixtures/issue528.go
Normal file
12
_fixtures/issue528.go
Normal file
@ -0,0 +1,12 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/peterh/liner"
|
||||
)
|
||||
|
||||
func main() {
|
||||
line := liner.NewLiner()
|
||||
line.Close()
|
||||
fmt.Printf("test\n")
|
||||
}
|
||||
@ -4,13 +4,13 @@ import (
|
||||
"fmt"
|
||||
"math/rand"
|
||||
"net"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strconv"
|
||||
"strings"
|
||||
"testing"
|
||||
"time"
|
||||
"os"
|
||||
|
||||
protest "github.com/derekparker/delve/proc/test"
|
||||
|
||||
@ -1100,3 +1100,20 @@ func TestEvalExprName(t *testing.T) {
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
func TestClientServer_Issue528(t *testing.T) {
|
||||
// FindLocation with Receiver.MethodName syntax does not work
|
||||
// on remote package names due to a bug in debug/gosym that
|
||||
// Was fixed in go 1.7 // Commit that fixes the issue in go:
|
||||
// f744717d1924340b8f5e5a385e99078693ad9097
|
||||
|
||||
ver, _ := proc.ParseVersionString(runtime.Version())
|
||||
if ver.Major > 0 && !ver.AfterOrEqual(proc.GoVersion{1, 7, 0, 0, 0}) {
|
||||
t.Log("Test skipped")
|
||||
return
|
||||
}
|
||||
|
||||
withTestClient2("issue528", t, func(c service.Client) {
|
||||
findLocationHelper(t, c, "State.Close", false, 1, 0)
|
||||
})
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user