mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
tests: Include etcd-last-release in BinPath
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
This commit is contained in:
parent
0f9e15fc37
commit
9bba38e51f
@ -38,7 +38,7 @@ func TestDowngradeUpgradeClusterOf3(t *testing.T) {
|
|||||||
|
|
||||||
func testDowngradeUpgrade(t *testing.T, clusterSize int) {
|
func testDowngradeUpgrade(t *testing.T, clusterSize int) {
|
||||||
currentEtcdBinary := e2e.BinPath.Etcd
|
currentEtcdBinary := e2e.BinPath.Etcd
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
if !fileutil.Exist(lastReleaseBinary) {
|
if !fileutil.Exist(lastReleaseBinary) {
|
||||||
t.Skipf("%q does not exist", lastReleaseBinary)
|
t.Skipf("%q does not exist", lastReleaseBinary)
|
||||||
}
|
}
|
||||||
|
@ -38,7 +38,7 @@ func TestTLSClusterOf3UsingDiscovery(t *testing.T) { testClusterUsingDiscovery(t
|
|||||||
func testClusterUsingDiscovery(t *testing.T, size int, peerTLS bool) {
|
func testClusterUsingDiscovery(t *testing.T, size int, peerTLS bool) {
|
||||||
e2e.BeforeTest(t)
|
e2e.BeforeTest(t)
|
||||||
|
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
if !fileutil.Exist(lastReleaseBinary) {
|
if !fileutil.Exist(lastReleaseBinary) {
|
||||||
t.Skipf("%q does not exist", lastReleaseBinary)
|
t.Skipf("%q does not exist", lastReleaseBinary)
|
||||||
}
|
}
|
||||||
|
@ -29,7 +29,7 @@ import (
|
|||||||
// TestReleaseUpgrade ensures that changes to master branch does not affect
|
// TestReleaseUpgrade ensures that changes to master branch does not affect
|
||||||
// upgrade from latest etcd releases.
|
// upgrade from latest etcd releases.
|
||||||
func TestReleaseUpgrade(t *testing.T) {
|
func TestReleaseUpgrade(t *testing.T) {
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
if !fileutil.Exist(lastReleaseBinary) {
|
if !fileutil.Exist(lastReleaseBinary) {
|
||||||
t.Skipf("%q does not exist", lastReleaseBinary)
|
t.Skipf("%q does not exist", lastReleaseBinary)
|
||||||
}
|
}
|
||||||
@ -113,7 +113,7 @@ func TestReleaseUpgrade(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func TestReleaseUpgradeWithRestart(t *testing.T) {
|
func TestReleaseUpgradeWithRestart(t *testing.T) {
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
if !fileutil.Exist(lastReleaseBinary) {
|
if !fileutil.Exist(lastReleaseBinary) {
|
||||||
t.Skipf("%q does not exist", lastReleaseBinary)
|
t.Skipf("%q does not exist", lastReleaseBinary)
|
||||||
}
|
}
|
||||||
|
@ -32,7 +32,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func TestEtctlutlMigrate(t *testing.T) {
|
func TestEtctlutlMigrate(t *testing.T) {
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
|
|
||||||
tcs := []struct {
|
tcs := []struct {
|
||||||
name string
|
name string
|
||||||
|
@ -75,7 +75,7 @@ func TestV2DeprecationFlags(t *testing.T) {
|
|||||||
e2e.BeforeTest(t)
|
e2e.BeforeTest(t)
|
||||||
dataDirPath := t.TempDir()
|
dataDirPath := t.TempDir()
|
||||||
|
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
if !fileutil.Exist(lastReleaseBinary) {
|
if !fileutil.Exist(lastReleaseBinary) {
|
||||||
t.Skipf("%q does not exist", lastReleaseBinary)
|
t.Skipf("%q does not exist", lastReleaseBinary)
|
||||||
}
|
}
|
||||||
@ -101,7 +101,7 @@ func TestV2DeprecationSnapshotMatches(t *testing.T) {
|
|||||||
ctx, cancel := context.WithCancel(context.Background())
|
ctx, cancel := context.WithCancel(context.Background())
|
||||||
defer cancel()
|
defer cancel()
|
||||||
|
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
currentReleaseBinary := e2e.BinPath.Etcd
|
currentReleaseBinary := e2e.BinPath.Etcd
|
||||||
|
|
||||||
if !fileutil.Exist(lastReleaseBinary) {
|
if !fileutil.Exist(lastReleaseBinary) {
|
||||||
@ -136,7 +136,7 @@ func TestV2DeprecationSnapshotRecover(t *testing.T) {
|
|||||||
ctx, cancel := context.WithCancel(context.Background())
|
ctx, cancel := context.WithCancel(context.Background())
|
||||||
defer cancel()
|
defer cancel()
|
||||||
|
|
||||||
lastReleaseBinary := e2e.BinDir + "/etcd-last-release"
|
lastReleaseBinary := e2e.BinPath.EtcdLastRelease
|
||||||
currentReleaseBinary := e2e.BinPath.Etcd
|
currentReleaseBinary := e2e.BinPath.Etcd
|
||||||
|
|
||||||
if !fileutil.Exist(lastReleaseBinary) {
|
if !fileutil.Exist(lastReleaseBinary) {
|
||||||
|
@ -41,6 +41,7 @@ func init() {
|
|||||||
func initBinPathCov(binDir string) binPath {
|
func initBinPathCov(binDir string) binPath {
|
||||||
return binPath{
|
return binPath{
|
||||||
Etcd: binDir + "/etcd_test",
|
Etcd: binDir + "/etcd_test",
|
||||||
|
EtcdLastRelease: binDir + "/etcd-last-release",
|
||||||
Etcdctl: binDir + "/etcdctl_test",
|
Etcdctl: binDir + "/etcdctl_test",
|
||||||
Etcdutl: binDir + "/etcdutl_test",
|
Etcdutl: binDir + "/etcdutl_test",
|
||||||
}
|
}
|
||||||
|
@ -34,6 +34,7 @@ func init() {
|
|||||||
func initBinPathNoCov(binDir string) binPath {
|
func initBinPathNoCov(binDir string) binPath {
|
||||||
return binPath{
|
return binPath{
|
||||||
Etcd: binDir + "/etcd",
|
Etcd: binDir + "/etcd",
|
||||||
|
EtcdLastRelease: binDir + "/etcd-last-release",
|
||||||
Etcdctl: binDir + "/etcdctl",
|
Etcdctl: binDir + "/etcdctl",
|
||||||
Etcdutl: binDir + "/etcdutl",
|
Etcdutl: binDir + "/etcdutl",
|
||||||
}
|
}
|
||||||
|
@ -46,6 +46,7 @@ var (
|
|||||||
|
|
||||||
type binPath struct {
|
type binPath struct {
|
||||||
Etcd string
|
Etcd string
|
||||||
|
EtcdLastRelease string
|
||||||
Etcdctl string
|
Etcdctl string
|
||||||
Etcdutl string
|
Etcdutl string
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user