mirror of https://github.com/dapr/cli.git
e2e for runtime version 1.4.0 (#796)
* check upgrade path for runtime version 1.4.0-rc.6 * Fix code typo * fix shutdown api usage in test * fix e2e tests for latest version
This commit is contained in:
parent
909b989128
commit
57bf146dfe
|
@ -24,3 +24,5 @@ cli
|
|||
|
||||
# CLI's auto-generated components directory
|
||||
**/components
|
||||
|
||||
test_output.json
|
|
@ -32,8 +32,8 @@ import (
|
|||
)
|
||||
|
||||
const (
|
||||
daprRuntimeVersion = "1.3.0"
|
||||
daprDashboardVersion = "0.7.0"
|
||||
daprRuntimeVersion = "1.4.0"
|
||||
daprDashboardVersion = "0.8.0"
|
||||
)
|
||||
|
||||
func TestStandaloneInstall(t *testing.T) {
|
||||
|
@ -364,7 +364,7 @@ func testRun(t *testing.T) {
|
|||
|
||||
t.Run("API shutdown", func(t *testing.T) {
|
||||
// Test that the CLI exits on a daprd shutdown.
|
||||
output, err := spawn.Command(daprPath, "run", "--dapr-http-port", "9999", "--", "bash", "-c", "curl -v http://localhost:9999/v1.0/shutdown; sleep 10; exit 1")
|
||||
output, err := spawn.Command(daprPath, "run", "--dapr-http-port", "9999", "--", "bash", "-c", "curl -v -X POST http://localhost:9999/v1.0/shutdown; sleep 10; exit 1")
|
||||
t.Log(output)
|
||||
require.NoError(t, err, "run failed")
|
||||
assert.Contains(t, output, "Exited App successfully", "App should be shutdown before it has a chance to return non-zero")
|
||||
|
|
|
@ -21,38 +21,6 @@ type upgradePath struct {
|
|||
|
||||
var (
|
||||
supportedUpgradePaths = []upgradePath{
|
||||
{
|
||||
previous: common.VersionDetails{
|
||||
RuntimeVersion: "1.1.0",
|
||||
DashboardVersion: "0.6.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
next: common.VersionDetails{
|
||||
RuntimeVersion: "1.1.1",
|
||||
DashboardVersion: "0.6.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
},
|
||||
{
|
||||
previous: common.VersionDetails{
|
||||
RuntimeVersion: "1.1.1",
|
||||
DashboardVersion: "0.6.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
next: common.VersionDetails{
|
||||
RuntimeVersion: "1.1.2",
|
||||
DashboardVersion: "0.6.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
},
|
||||
{
|
||||
previous: common.VersionDetails{
|
||||
RuntimeVersion: "1.1.2",
|
||||
|
@ -87,19 +55,35 @@ var (
|
|||
},
|
||||
{
|
||||
previous: common.VersionDetails{
|
||||
RuntimeVersion: "1.2.2",
|
||||
DashboardVersion: "0.6.0",
|
||||
RuntimeVersion: "1.3.0",
|
||||
DashboardVersion: "0.7.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
next: common.VersionDetails{
|
||||
RuntimeVersion: "1.3.0",
|
||||
RuntimeVersion: "1.4.0",
|
||||
DashboardVersion: "0.8.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
},
|
||||
{
|
||||
previous: common.VersionDetails{
|
||||
RuntimeVersion: "1.3.1",
|
||||
DashboardVersion: "0.7.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
next: common.VersionDetails{
|
||||
RuntimeVersion: "1.4.0",
|
||||
DashboardVersion: "0.8.0",
|
||||
ClusterRoles: []string{"dapr-operator-admin", "dashboard-reader"},
|
||||
ClusterRoleBindings: []string{"dapr-operator", "dapr-role-tokenreview-binding", "dashboard-reader-global"},
|
||||
CustomResourceDefs: []string{"components.dapr.io", "configurations.dapr.io", "subscriptions.dapr.io"},
|
||||
},
|
||||
},
|
||||
}
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue