This is an automated email from the ASF dual-hosted git repository.

astefanutti pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel-k.git

commit b48246037a75beaa0a1cd12d8bc591f284c70c41
Author: Pasquale Congiusti <[email protected]>
AuthorDate: Fri Jan 29 15:33:17 2021 +0100

    feat(cmd): compress-binary no longer needed
    
    With #1946 we are no longer needing a special `compress-binary` flag
---
 pkg/cmd/run.go      |  2 --
 pkg/cmd/run_test.go | 10 +---------
 2 files changed, 1 insertion(+), 11 deletions(-)

diff --git a/pkg/cmd/run.go b/pkg/cmd/run.go
index 8ac482e..874c443 100644
--- a/pkg/cmd/run.go
+++ b/pkg/cmd/run.go
@@ -88,7 +88,6 @@ func newCmdRun(rootCmdOptions *RootCmdOptions) 
(*cobra.Command, *runCmdOptions)
        cmd.Flags().StringArray("logging-level", nil, "Configure the logging 
level. e.g. \"--logging-level org.apache.camel=DEBUG\"")
        cmd.Flags().StringP("output", "o", "", "Output format. One of: 
json|yaml")
        cmd.Flags().Bool("compression", false, "Enable storage of sources and 
resources as a compressed binary blobs")
-       cmd.Flags().Bool("compress-binary", true, "Enable compression of 
sources and resources having a binary content type (to encode them)")
        cmd.Flags().StringArray("resource", nil, "Add a resource")
        cmd.Flags().StringArray("open-api", nil, "Add an OpenAPI v2 spec")
        cmd.Flags().StringArrayP("volume", "v", nil, "Mount a volume into the 
integration container. E.g \"-v pvcname:/container/path\"")
@@ -108,7 +107,6 @@ func newCmdRun(rootCmdOptions *RootCmdOptions) 
(*cobra.Command, *runCmdOptions)
 type runCmdOptions struct {
        *RootCmdOptions `json:"-"`
        Compression     bool     `mapstructure:"compression" yaml:",omitempty"`
-       CompressBinary  bool     `mapstructure:"compress-binary" 
yaml:",omitempty"`
        Wait            bool     `mapstructure:"wait" yaml:",omitempty"`
        Logs            bool     `mapstructure:"logs" yaml:",omitempty"`
        Sync            bool     `mapstructure:"sync" yaml:",omitempty"`
diff --git a/pkg/cmd/run_test.go b/pkg/cmd/run_test.go
index 2dda764..eddb32f 100644
--- a/pkg/cmd/run_test.go
+++ b/pkg/cmd/run_test.go
@@ -65,7 +65,6 @@ func TestRunNoFlag(t *testing.T) {
        assert.Equal(t, false, runCmdOptions.Dev)
        assert.Equal(t, true, runCmdOptions.UseFlows)
        assert.Equal(t, false, runCmdOptions.Compression)
-       assert.Equal(t, true, runCmdOptions.CompressBinary)
        assert.Equal(t, false, runCmdOptions.Save)
 }
 
@@ -75,18 +74,11 @@ func TestRunNonExistingFlag(t *testing.T) {
        assert.NotNil(t, err)
 }
 
-func TestRunCompressBinaryFlag(t *testing.T) {
-       runCmdOptions, rootCmd, _ := initializeRunCmdOptions(t)
-       _, err := test.ExecuteCommand(rootCmd, cmdRun, 
"--compress-binary=false", integrationSource)
-       assert.Nil(t, err)
-       assert.Equal(t, false, runCmdOptions.CompressBinary)
-}
-
 func TestRunCompressionFlag(t *testing.T) {
        runCmdOptions, rootCmd, _ := initializeRunCmdOptions(t)
        _, err := test.ExecuteCommand(rootCmd, cmdRun, "--compression", 
integrationSource)
        assert.Nil(t, err)
-       assert.Equal(t, true, runCmdOptions.CompressBinary)
+       assert.Equal(t, true, runCmdOptions.Compression)
 }
 
 func TestRunConfigMapFlag(t *testing.T) {

Reply via email to