Skip to content
Snippets Groups Projects
Commit e222e408 authored by Riabokon Stanislav(EPAM)[GCP]'s avatar Riabokon Stanislav(EPAM)[GCP]
Browse files

Merge branch 'bugfix/GONRG-2074-Incorrect-response' into 'integration-master'

Incorrect response for incorrect request

Closes GONRG-2074

See merge request go3-nrg/platform/System/partition!36
parents a7bd02e1 6a629c7e
No related branches found
No related tags found
2 merge requests!47Authentication for PartitionService to work under SA(GONRG-1843),!45(GONRG-2074) GCP incorrect response
Pipeline #33766 failed
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
package org.opengroup.osdu.partition.model; package org.opengroup.osdu.partition.model;
import javax.validation.constraints.NotEmpty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Builder; import lombok.Builder;
import lombok.Data; import lombok.Data;
...@@ -28,6 +29,7 @@ import java.util.Map; ...@@ -28,6 +29,7 @@ import java.util.Map;
@NoArgsConstructor @NoArgsConstructor
public class PartitionInfo { public class PartitionInfo {
@NotEmpty
@Builder.Default @Builder.Default
Map<String, Property> properties = new HashMap<>(); Map<String, Property> properties = new HashMap<>();
} }
\ No newline at end of file
...@@ -42,7 +42,7 @@ public class TestCreatePartition extends CreatePartitionTest { ...@@ -42,7 +42,7 @@ public class TestCreatePartition extends CreatePartitionTest {
@Override @Override
@Test @Test
public void should_return40XResponseCode_when_makingRequest_withInvalidPayload() throws Exception { public void should_return40XResponseCode_when_makingRequest_withInvalidPayload() throws Exception {
String invalidPayload = "invalidPayload"; String invalidPayload = "{\"properties_invalid\":{}}";
ClientResponse response = descriptor.runWithCustomPayload(getId(), invalidPayload, testUtils.getAccessToken()); ClientResponse response = descriptor.runWithCustomPayload(getId(), invalidPayload, testUtils.getAccessToken());
assertEquals(400, response.getStatus()); assertEquals(400, response.getStatus());
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment