Skip to content

Commit 6d4007a

Browse files
committed
Merge branch 'users/svegiraju/spring-pom-update' of https://github.com/siri-varma/java-sdk into users/svegiraju/spring-pom-update
2 parents 2ef6929 + 14d05a7 commit 6d4007a

File tree

4 files changed

+10
-18
lines changed

4 files changed

+10
-18
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ jobs:
121121
env:
122122
DOCKER_HOST: ${{steps.setup_docker.outputs.sock}}
123123
- name: Codecov
124-
uses: codecov/[email protected].2
124+
uses: codecov/[email protected].3
125125
- name: Install jars
126126
run: ./mvnw install -q -B -DskipTests
127127
- name: Integration tests using spring boot version ${{ matrix.spring-boot-version }}

.github/workflows/fossa.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,12 @@ jobs:
3535
uses: actions/checkout@v4
3636

3737
- name: "Run FOSSA Scan"
38-
uses: fossas/fossa-action@v1.6.0 # Use a specific version if locking is preferred
38+
uses: fossas/fossa-action@v1.7.0 # Use a specific version if locking is preferred
3939
with:
4040
api-key: ${{ env.FOSSA_API_KEY }}
4141

4242
- name: "Run FOSSA Test"
43-
uses: fossas/fossa-action@v1.6.0 # Use a specific version if locking is preferred
43+
uses: fossas/fossa-action@v1.7.0 # Use a specific version if locking is preferred
4444
with:
4545
api-key: ${{ env.FOSSA_API_KEY }}
4646
run-tests: true

testcontainers-dapr/src/main/java/io/dapr/testcontainers/DaprContainer.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -210,21 +210,19 @@ public DaprContainer withComponent(Path path) {
210210
try {
211211
Map<String, Object> component = YAML_MAPPER.loadAs(Files.newInputStream(path), Map.class);
212212

213-
String type = (String) component.get("type");
214213
Map<String, Object> metadata = (Map<String, Object>) component.get("metadata");
215214
String name = (String) metadata.get("name");
216215

217216
Map<String, Object> spec = (Map<String, Object>) component.get("spec");
217+
String type = (String) spec.get("type");
218218
String version = (String) spec.get("version");
219219
List<Map<String, String>> specMetadata =
220-
(List<Map<String, String>>) spec.getOrDefault("metadata", Collections.emptyMap());
220+
(List<Map<String, String>>) spec.getOrDefault("metadata", Collections.emptyList());
221221

222222
ArrayList<MetadataEntry> metadataEntries = new ArrayList<>();
223223

224224
for (Map<String, String> specMetadataItem : specMetadata) {
225-
for (Map.Entry<String, String> metadataItem : specMetadataItem.entrySet()) {
226-
metadataEntries.add(new MetadataEntry(metadataItem.getKey(), metadataItem.getValue()));
227-
}
225+
metadataEntries.add(new MetadataEntry(specMetadataItem.get("name"), specMetadataItem.get("value")));
228226
}
229227

230228
return withComponent(new Component(name, type, version, metadataEntries));

testcontainers-dapr/src/test/java/io/dapr/testcontainers/DaprComponentTest.java

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -69,20 +69,14 @@ public void withComponentFromPath() {
6969
+ "metadata:\n"
7070
+ " name: statestore\n"
7171
+ "spec:\n"
72-
+ " type: null\n"
72+
+ " type: state.redis\n"
7373
+ " version: v1\n"
7474
+ " metadata:\n"
75-
+ " - name: name\n"
76-
+ " value: keyPrefix\n"
77-
+ " - name: value\n"
75+
+ " - name: keyPrefix\n"
7876
+ " value: name\n"
79-
+ " - name: name\n"
80-
+ " value: redisHost\n"
81-
+ " - name: value\n"
77+
+ " - name: redisHost\n"
8278
+ " value: redis:6379\n"
83-
+ " - name: name\n"
84-
+ " value: redisPassword\n"
85-
+ " - name: value\n"
79+
+ " - name: redisPassword\n"
8680
+ " value: ''\n";
8781

8882
assertEquals(expectedComponentYaml, componentYaml);

0 commit comments

Comments
 (0)