Skip to content

Helm install fails using cargo run from flv-test crate root #859

Closed
@tjtelan

Description

Currently, the test runner only works when run when your current working directory is the Fluvio git repo's root. The Helm chart's location is identified using relative paths assuming the pwd.

panic panicked at 'Failed to install k8 cluster: InstallK8(HelmError(Command(CommandError { command: "helm install fluvio ./k8-util/helm/fluvio-app --namespace default --devel --version 0.7.1-alpha.0 --set image.registry=infinyon --set image.tag=e1b71dea26d31e58abee5eaf25e6bf2cf6bd5bd8 --set cloud=minikube", source: ExitError(1) })))', tests/runner/src/utils/setup/environment/k8.rs:54:14

Workaround:
cd to the fluvio repo root if you want to run tests.

Example error when trying to run test from test runner crate:

$ pwd
/home/telant/Documents/fluvio/tests/runner

$ cargo run -- smoke --develop
[...]
Running `/home/telant/Documents/fluvio/target/debug/flv-test smoke --develop`
Start running fluvio test runner
deleting cluster
installing cluster
panic panicked at 'Failed to install k8 cluster: InstallK8(HelmError(Command(CommandError { command: "helm install fluvio ./k8-util/helm/fluvio-app --namespace default --devel --version 0.7.1-alpha.0 --set image.registry=infinyon --set image.tag=e1b71dea26d31e58abee5eaf25e6bf2cf6bd5bd8 --set cloud=minikube", source: ExitError(1) })))', tests/runner/src/utils/setup/environment/k8.rs:54:14

But after cding up two levels to the crate root:

$ cd ../../
$ pwd
/home/telant/Documents/fluvio/

$ cargo run --bin flv-test -- smoke --develop

Start running fluvio test runner
deleting cluster
installing cluster
Waiting up to 120 seconds for Fluvio cluster version check...
Creating the topic: topic
found topic: topic offset: 0
starting produce
Executing: /home/telant/Documents/fluvio/target/debug/fluvio produce topic
Ok!
send message of len 121
Executing> /home/telant/Documents/fluvio/target/debug/fluvio consume topic --partition 0 -d -o 0
topic: topic, consume message validated!
deleting cluster

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions