Skip to content

Commit b9d81d4

Browse files
authored
refactor: move tests to a separate project to simplify build (special… (#558)
* refactor: move tests to a separate project to simplify build (specially in IDEs) refactor: move tests to a separate project to simplify build (specially in IDEs) * fix(ci): update cache path and add restore keys for Maven dependencies - Corrected the cache path from `~/.mv2/repository` to `~/.m2/repository` - Added restore keys to improve cache retrieval during CI runs - Included a step to save the cache after dependencies are downloaded
1 parent caff5c2 commit b9d81d4

File tree

400 files changed

+36065
-74
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

400 files changed

+36065
-74
lines changed

.github/workflows/integration.yml

+31-21
Original file line numberDiff line numberDiff line change
@@ -13,24 +13,34 @@ jobs:
1313
runs-on: ${{ matrix.platform }}
1414

1515
steps:
16-
- uses: actions/checkout@v3
17-
- name: cache
18-
uses: actions/cache@v4
19-
with:
20-
path: |
21-
~/.mv2/repository
22-
key: om-${{hashFiles('**/pom.xml')}}
23-
24-
- name: Set up JDK 21
25-
uses: actions/setup-java@v2
26-
with:
27-
java-version: 21
28-
distribution: 'zulu'
29-
- run: mvn dependency:go-offline
30-
- name: Build
31-
run: mvn clean process-test-classes verify
32-
33-
- name: Upload coverage reports to Codecov
34-
uses: codecov/[email protected]
35-
with:
36-
token: ${{ secrets.CODECOV_TOKEN }}
16+
- uses: actions/checkout@v3
17+
18+
- name: Cache Maven Repository
19+
uses: actions/cache@v4
20+
with:
21+
path: ~/.m2/repository
22+
key: om-${{ hashFiles('**/pom.xml') }}
23+
restore-keys: |
24+
om-
25+
26+
- name: Set up JDK 21
27+
uses: actions/setup-java@v2
28+
with:
29+
java-version: 21
30+
distribution: 'zulu'
31+
32+
- run: mvn dependency:go-offline
33+
34+
- name: Build
35+
run: mvn clean process-test-classes verify
36+
37+
- name: Save Maven Cache
38+
uses: actions/cache@v4
39+
with:
40+
path: ~/.m2/repository
41+
key: om-${{ hashFiles('**/pom.xml') }}
42+
43+
- name: Upload coverage reports to Codecov
44+
uses: codecov/[email protected]
45+
with:
46+
token: ${{ secrets.CODECOV_TOKEN }}

pom.xml

+1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
<modules>
2424
<!-- Main Project -->
2525
<module>redis-om-spring</module>
26+
<module>tests</module>
2627
<!-- Demos -->
2728
<module>demos/roms-documents</module>
2829
<module>demos/roms-hashes</module>

redis-om-spring/pom.xml

-53
Original file line numberDiff line numberDiff line change
@@ -290,59 +290,6 @@
290290
<version>${djl.version}</version>
291291
<optional>true</optional>
292292
</dependency>
293-
294-
<!-- test dependencies -->
295-
<dependency>
296-
<groupId>org.junit.jupiter</groupId>
297-
<artifactId>junit-jupiter</artifactId>
298-
<scope>test</scope>
299-
</dependency>
300-
<dependency>
301-
<groupId>org.assertj</groupId>
302-
<artifactId>assertj-core</artifactId>
303-
<version>${assertj.version}</version>
304-
<scope>test</scope>
305-
</dependency>
306-
<dependency>
307-
<groupId>org.springframework</groupId>
308-
<artifactId>spring-test</artifactId>
309-
<scope>test</scope>
310-
</dependency>
311-
<dependency>
312-
<groupId>org.springframework.boot</groupId>
313-
<artifactId>spring-boot-starter-test</artifactId>
314-
<scope>test</scope>
315-
<exclusions>
316-
<exclusion>
317-
<groupId>com.vaadin.external.google</groupId>
318-
<artifactId>android-json</artifactId>
319-
</exclusion>
320-
</exclusions>
321-
</dependency>
322-
<dependency>
323-
<groupId>com.redis</groupId>
324-
<artifactId>testcontainers-redis</artifactId>
325-
<version>${testcontainers.redis.version}</version>
326-
<scope>test</scope>
327-
</dependency>
328-
<dependency>
329-
<groupId>com.karuslabs</groupId>
330-
<artifactId>elementary</artifactId>
331-
<version>${elementary.version}</version>
332-
<scope>test</scope>
333-
</dependency>
334-
<dependency>
335-
<groupId>org.projectlombok</groupId>
336-
<artifactId>lombok</artifactId>
337-
<version>${lombok.version}</version>
338-
<scope>test</scope>
339-
</dependency>
340-
<dependency>
341-
<groupId>org.testcontainers</groupId>
342-
<artifactId>junit-jupiter</artifactId>
343-
<version>${testcontainers.junit.jupiter}</version>
344-
<scope>test</scope>
345-
</dependency>
346293
<dependency>
347294
<groupId>com.fasterxml.jackson.core</groupId>
348295
<artifactId>jackson-databind</artifactId>

0 commit comments

Comments
 (0)