@@ -14,6 +14,9 @@ setup_file() {
14
14
15
15
CLI_VERSION=" ${CLI_VERSION:- latest} "
16
16
export CLI_VERSION
17
+
18
+ FLUVIO_CLIENT_BIN=" ${FLUVIO_CLIENT_BIN:- $HOME / .fvm/ versions/ $CLI_VERSION / fluvio} "
19
+ export FLUVIO_CLIENT_BIN
17
20
18
21
PAYLOAD_SIZE=" ${PAYLOAD_SIZE:- 100} "
19
22
export PAYLOAD_SIZE
@@ -34,7 +37,7 @@ setup_file() {
34
37
if [[ -z " $CI " ]];
35
38
then
36
39
echo " # Deleting cluster" >&3
37
- " $FLUVIO_BIN " cluster delete --force"
40
+ " $FLUVIO_BIN " cluster delete --force
38
41
else
39
42
echo " # [CI MODE] Skipping initial cleanup" >&3
40
43
fi ;
@@ -57,32 +60,30 @@ teardown_file() {
57
60
if [[ -z " $SKIP_CLEANUP " ]];
58
61
then
59
62
echo " # Deleting cluster" >&3
60
- " $FLUVIO_BIN " cluster delete --force"
63
+ " $FLUVIO_BIN " cluster delete --force
61
64
else
62
65
echo " # Skipping cleanup" >&3
63
66
fi
64
-
65
- # run timeout 15s "$FLUVIO_BIN" topic delete "$TOPIC_NAME"
66
67
}
67
68
68
69
# Create topic
69
70
@test " Create a topic: $TOPIC_NAME " {
70
71
debug_msg " topic: $TOPIC_NAME "
71
- run timeout 15s " $FLUVIO_BIN " topic create " $TOPIC_NAME "
72
+ run timeout 15s " $FLUVIO_CLIENT_BIN " topic create " $TOPIC_NAME "
72
73
assert_success
73
74
}
74
75
75
76
# Produce message
76
77
@test " Produce message" {
77
- run bash -c ' echo "$MESSAGE" | timeout 15s "$FLUVIO_BIN " produce "$TOPIC_NAME"'
78
+ run bash -c ' echo "$MESSAGE" | timeout 15s "$FLUVIO_CLIENT_BIN " produce "$TOPIC_NAME"'
78
79
79
80
assert_success
80
81
}
81
82
82
83
# Consume message and compare message
83
84
# Warning: Adding anything extra to the `debug_msg` skews the message comparison
84
85
@test " Consume message" {
85
- run timeout 15s " $FLUVIO_BIN " consume " $TOPIC_NAME " -B -d
86
+ run timeout 15s " $FLUVIO_CLIENT_BIN " consume " $TOPIC_NAME " -B -d
86
87
87
88
assert_output --partial " $MESSAGE "
88
89
assert_success
0 commit comments