Browse Source

e2e: remove colorized output from docker-compose (#6670)

pull/6682/head
Sam Kleinman 4 years ago
committed by GitHub
parent
commit
cd248576ea
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 6 deletions
  1. +2
    -2
      test/e2e/runner/exec.go
  2. +1
    -4
      test/e2e/runner/main.go

+ 2
- 2
test/e2e/runner/exec.go View File

@ -33,14 +33,14 @@ func execVerbose(args ...string) error {
// execCompose runs a Docker Compose command for a testnet.
func execCompose(dir string, args ...string) error {
return exec(append(
[]string{"docker-compose", "-f", filepath.Join(dir, "docker-compose.yml")},
[]string{"docker-compose", "--ansi=never", "-f", filepath.Join(dir, "docker-compose.yml")},
args...)...)
}
// execComposeVerbose runs a Docker Compose command for a testnet and displays its output.
func execComposeVerbose(dir string, args ...string) error {
return execVerbose(append(
[]string{"docker-compose", "-f", filepath.Join(dir, "docker-compose.yml")},
[]string{"docker-compose", "--ansi=never", "-f", filepath.Join(dir, "docker-compose.yml")},
args...)...)
}


+ 1
- 4
test/e2e/runner/main.go View File

@ -235,10 +235,7 @@ func NewCLI() *CLI {
Example: "runner logs validator03",
Args: cobra.MaximumNArgs(1),
RunE: func(cmd *cobra.Command, args []string) error {
if len(args) == 1 {
return execComposeVerbose(cli.testnet.Dir, "logs", args[0])
}
return execComposeVerbose(cli.testnet.Dir, "logs")
return execComposeVerbose(cli.testnet.Dir, append([]string{"logs", "--no-color"}, args...)...)
},
})


Loading…
Cancel
Save