@@ -14,6 +14,10 @@ inputs:
14
14
description : ' hiredis version to test against'
15
15
required : false
16
16
default : ' >3.0.0'
17
+ hiredis-branch :
18
+ description : ' hiredis branch to test against'
19
+ required : false
20
+ default : ' master'
17
21
event-loop :
18
22
description : ' Event loop to use'
19
23
required : false
28
32
python-version : ${{ inputs.python-version }}
29
33
cache : ' pip'
30
34
35
+ - uses : actions/checkout@v4
36
+ if : ${{ inputs.parser-backend == 'hiredis' && inputs.hiredis-version == 'unstable' }}
37
+ with :
38
+ repository : redis/hiredis-py
39
+ submodules : true
40
+ path : hiredis-py
41
+ ref : ${{ inputs.hiredis-branch }}
42
+
31
43
- name : Setup Test environment
32
44
env :
33
45
REDIS_VERSION : ${{ inputs.redis-version }}
40
52
pip uninstall -y redis # uninstall Redis package installed via redis-entraid
41
53
pip install -e .[jwt] # install the working copy
42
54
if [ "${{inputs.parser-backend}}" == "hiredis" ]; then
43
- pip install "hiredis${{inputs.hiredis-version}}"
44
- echo "PARSER_BACKEND=$(echo "${{inputs.parser-backend}}_${{inputs.hiredis-version}}" | sed 's/[^a-zA-Z0-9]/_/g')" >> $GITHUB_ENV
55
+ if [[ "${{inputs.hiredis-version}}" == "unstable" ]]; then
56
+ echo "Installing unstable version of hiredis from local directory"
57
+ pip install -e ./hiredis-py
58
+ else
59
+ pip install "hiredis${{inputs.hiredis-version}}"
60
+ fi
61
+ echo "PARSER_BACKEND=$(echo "${{inputs.parser-backend}}_${{inputs.hiredis-version}}" | sed 's/[^a-zA-Z0-9]/_/g')" >> $GITHUB_ENV
45
62
else
46
63
echo "PARSER_BACKEND=${{inputs.parser-backend}}" >> $GITHUB_ENV
47
64
fi
@@ -108,12 +125,10 @@ runs:
108
125
fi
109
126
110
127
echo "::endgroup::"
111
-
112
- if [ "$protocol" == "2" ] || [ "${{inputs.parser-backend}}" != 'hiredis' ]; then
113
- echo "::group::RESP${protocol} cluster tests"
114
- invoke cluster-tests $eventloop --protocol=${protocol}
115
- echo "::endgroup::"
116
- fi
128
+
129
+ echo "::group::RESP${protocol} cluster tests"
130
+ invoke cluster-tests $eventloop --protocol=${protocol}
131
+ echo "::endgroup::"
117
132
}
118
133
119
134
run_tests 2 "${{inputs.event-loop}}"
0 commit comments