File tree Expand file tree Collapse file tree 4 files changed +69
-3
lines changed Expand file tree Collapse file tree 4 files changed +69
-3
lines changed Original file line number Diff line number Diff line change 4242 uses : codecov/codecov-action@v5
4343 with :
4444 files : coverage.txt
45- token : ${{ secrets.CODECOV_TOKEN }}
45+ token : ${{ secrets.CODECOV_TOKEN }}
46+
47+ test-redis-ce :
48+ name : test-redis-ce
49+ runs-on : ubuntu-latest
50+ strategy :
51+ fail-fast : false
52+ matrix :
53+ redis_version :
54+ - " 8.0-M01"
55+ - " 7.4.1"
56+ - " 7.2.6"
57+ - " 6.2.16"
58+ go-version :
59+ - " 1.19.x"
60+ - " 1.20.x"
61+ - " 1.21.x"
62+
63+ steps :
64+ - name : Set up ${{ matrix.go-version }}
65+ uses : actions/setup-go@v5
66+ with :
67+ go-version : ${{ matrix.go-version }}
68+
69+ - name : Checkout code
70+ uses : actions/checkout@v4
71+
72+ # Set up Docker Compose environment
73+ - name : Set up Docker Compose environment
74+ run : |
75+ docker compose --profile all up -d
76+
77+ - name : Run tests
78+ env :
79+ USE_CONTAINERIZED_REDIS : " true"
80+ RE_CLUSTER : " true"
81+ run : |
82+ go test \
83+ --ginkgo.skip-file="ring_test.go" \
84+ --ginkgo.skip-file="sentinel_test.go" \
85+ --ginkgo.skip-file="osscluster_test.go" \
86+ --ginkgo.skip-file="pubsub_test.go" \
87+ --ginkgo.skip-file="gears_commands_test.go" \
88+ --ginkgo.label-filter='!NonRedisEnterprise'
Original file line number Diff line number Diff line change 4747 - name : Test
4848 env :
4949 RE_CLUSTER : " 1"
50+ USE_CONTAINERIZED_REDIS : " 1"
5051 run : |
5152 go test \
5253 --ginkgo.skip-file="ring_test.go" \
Original file line number Diff line number Diff line change 1+ ---
2+
3+ services :
4+
5+ redis-stanalone :
6+ image : redislabs/client-libs-test:8.0-M02
7+ container_name : redis-standalone
8+ environment :
9+ - REDIS_CLUSTER=no
10+ - PORT=6379
11+ - TLS_PORT=6666
12+ command : --loadmodule /usr/local/lib/redis/modules/redisbloom.so --loadmodule /usr/local/lib/redis/modules/redisearch.so --loadmodule /usr/local/lib/redis/modules/redistimeseries.so --loadmodule /usr/local/lib/redis/modules/rejson.so
13+ ports :
14+ - 6379:6379
15+ - 6380:6379
16+ - 6666:6666 # TLS port
17+ volumes :
18+ - " ./dockers/redis-standalone:/redis/work"
19+ profiles :
20+ - standalone
21+ - all
Original file line number Diff line number Diff line change @@ -66,6 +66,7 @@ var cluster = &clusterScenario{
6666}
6767
6868var RECluster = false
69+ var USE_CONTAINERIZED_REDIS = false
6970
7071func registerProcess (port string , p * redisProcess ) {
7172 if processes == nil {
@@ -82,8 +83,8 @@ var _ = BeforeSuite(func() {
8283 }
8384 var err error
8485 RECluster , _ = strconv .ParseBool (os .Getenv ("RE_CLUSTER" ))
85-
86- if ! RECluster {
86+ USE_CONTAINERIZED_REDIS , _ = strconv . ParseBool ( os . Getenv ( "USE_CONTAINERIZED_REDIS" ))
87+ if ! RECluster || ! USE_CONTAINERIZED_REDIS {
8788
8889 redisMain , err = startRedis (redisPort )
8990 Expect (err ).NotTo (HaveOccurred ())
You can’t perform that action at this time.
0 commit comments