Skip to content

Commit

Permalink
Fix two failing integration tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
EricWittmann committed Mar 6, 2024
1 parent 3154558 commit e36926c
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 20 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package io.apicurio.tests.smokeTests.apicurio;

import static org.hamcrest.CoreMatchers.is;
import static org.hamcrest.CoreMatchers.notNullValue;
import static org.hamcrest.CoreMatchers.nullValue;
import static org.hamcrest.MatcherAssert.assertThat;

Expand Down Expand Up @@ -98,15 +97,6 @@ void getAndUpdateMetadataOfArtifactSpecificVersion() throws Exception {

registryClient.groups().byGroupId(groupId).artifacts().byArtifactId(artifactId).versions().byVersionExpression("2").meta().put(emd);

retryOp((rc) -> {
ArtifactMetaData artifactMetaData = rc.groups().byGroupId(groupId).artifacts().byArtifactId(artifactId).get();
LOGGER.info("Got metadata of artifact with ID {}: {}", artifactId, artifactMetaData);
assertThat(artifactMetaData.getType(), is("AVRO"));
assertThat(artifactMetaData.getName(), is("Artifact Updated Name"));
assertThat(artifactMetaData.getDescription(), is("The description of the artifact."));
assertThat(artifactMetaData.getModifiedOn(), notNullValue());
});

versionMetaData = registryClient.groups().byGroupId(groupId).artifacts().byArtifactId(artifactId).versions().byVersionExpression("1").meta().get();

LOGGER.info("Got metadata of artifact with ID {} version 1: {}", artifactId, versionMetaData);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ void createConfluentQueryApicurio() throws IOException, RestClientException, Tim

assertThat(1, is(confluentService.getAllSubjects().size()));

Response ar = ArtifactUtils.getArtifact("default", subjectName);
Response ar = ArtifactUtils.getArtifact("default", subjectName, "branch=latest", 200);
assertEquals(rawSchema, ar.asString());
LOGGER.info(ar.asString());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,6 @@

public class ArtifactUtils {


public static Response getArtifact(String groupId, String artifactId) {
return getArtifact(groupId, artifactId, "", 200);
}

public static Response getArtifact(String groupId, String artifactId, int returnCode) {
return getArtifact(groupId, artifactId, "", returnCode);
}

public static Response getArtifact(String groupId, String artifactId, String version, int returnCode) {
return
BaseHttpUtils.getRequest(RestConstants.JSON, ApicurioRegistryBaseIT.getRegistryV3ApiUrl() + "/groups/" + encodeURIComponent(groupId) + "/artifacts/" + encodeURIComponent(artifactId) + "/" + version, returnCode);
Expand Down

0 comments on commit e36926c

Please sign in to comment.