Skip to content

Commit 4e43653

Browse files
committed
test: re-enable init e2e tests
1 parent d7eebc0 commit 4e43653

4 files changed

Lines changed: 322 additions & 313 deletions

File tree

cmd/init.go

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ const (
6161

6262
// InitCmd is a struct that defines a command call for "init"
6363
type InitCmd struct {
64+
*flags.GlobalFlags
65+
6466
// Flags
6567
Reconfigure bool
6668
Dockerfile string
@@ -72,7 +74,8 @@ type InitCmd struct {
7274
// NewInitCmd creates a new init command
7375
func NewInitCmd(f factory.Factory) *cobra.Command {
7476
cmd := &InitCmd{
75-
log: f.GetLog(),
77+
log: f.GetLog(),
78+
GlobalFlags: globalFlags,
7679
}
7780

7881
initCmd := &cobra.Command{
@@ -201,7 +204,7 @@ func (cmd *InitCmd) initDevspace(f factory.Factory, configLoader loader.ConfigLo
201204
var config *latest.Config
202205

203206
// create kubectl client
204-
client, err := f.NewKubeClientFromContext(globalFlags.KubeContext, globalFlags.Namespace)
207+
client, err := f.NewKubeClientFromContext(cmd.GlobalFlags.KubeContext, cmd.GlobalFlags.Namespace)
205208
if err == nil {
206209
configInterface, err := configLoader.Load(context.TODO(), client, &loader.ConfigOptions{}, cmd.log)
207210
if err == nil {
@@ -728,6 +731,7 @@ func (cmd *InitCmd) render(f factory.Factory, config *latest.Config) (string, er
728731
Silent: true,
729732
ConfigPath: renderPath,
730733
},
734+
Pipeline: "deploy",
731735
SkipPush: true,
732736
SkipBuild: true,
733737
Render: true,

0 commit comments

Comments
 (0)