Skip to content

Commit

Permalink
Merge pull request DependencyTrack#3515 from DependencyTrack/nscuro-p…
Browse files Browse the repository at this point in the history
…atch-1

Bump Alpine to `2.2.5`
  • Loading branch information
nscuro authored Mar 1, 2024
2 parents 435bf7c + 7c3714c commit 8b23434
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 5 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<parent>
<groupId>us.springett</groupId>
<artifactId>alpine-parent</artifactId>
<version>2.2.5-SNAPSHOT</version>
<version>2.2.5</version>
</parent>

<modelVersion>4.0.0</modelVersion>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ public void addTeamToRuleWithCustomEmailPublisherTest() {
"teams": [
{
"uuid": "${json-unit.matches:teamUuid}",
"name": "Team Example"
"name": "Team Example",
"permissions": []
}
],
"notifyOn": [],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
import org.glassfish.jersey.servlet.ServletContainer;
import org.glassfish.jersey.test.DeploymentContext;
import org.glassfish.jersey.test.ServletDeploymentContext;
import org.hamcrest.CoreMatchers;
import org.junit.After;
import org.junit.Assert;
import org.junit.Test;
Expand Down Expand Up @@ -725,9 +726,24 @@ public void patchProjectParentTest() {

assertThat(response.getStatus()).isEqualTo(Response.Status.OK.getStatusCode());

final JsonObject responseJson = parseJsonObject(response);
assertThat(responseJson.getString("uuid")).isEqualTo(project.getUuid().toString());
assertThat(responseJson.getJsonObject("parent")).isNull(); // Parents are currently not returned
assertThatJson(getPlainTextBody(response))
.withMatcher("projectUuid", CoreMatchers.equalTo(project.getUuid().toString()))
.withMatcher("parentProjectUuid", CoreMatchers.equalTo(newParent.getUuid().toString()))
.isEqualTo("""
{
"name": "DEF",
"version": "2.0",
"uuid": "${json-unit.matches:projectUuid}",
"parent": {
"name": "GHI",
"version": "3.0",
"uuid": "${json-unit.matches:parentProjectUuid}"
},
"properties": [],
"tags": [],
"active": true
}
""");

// Ensure the parent was updated.
qm.getPersistenceManager().refresh(project);
Expand Down

0 comments on commit 8b23434

Please sign in to comment.