Skip to content

Commit

Permalink
Fix failing tests due to Proto package change
Browse files Browse the repository at this point in the history
Signed-off-by: nscuro <[email protected]>
  • Loading branch information
nscuro committed Sep 27, 2023
1 parent 1d78e4b commit 2b035e4
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import org.dependencytrack.tasks.BomUploadProcessingTask;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;

import java.io.File;
Expand Down Expand Up @@ -580,7 +581,7 @@ public void testEvaluateProjectWithScriptExecutionException() {
public void testEvaluateProjectWithFuncProjectDependsOnComponent() {
final var policy = qm.createPolicy("policy", Policy.Operator.ANY, Policy.ViolationState.FAIL);
qm.createPolicyCondition(policy, PolicyCondition.Subject.EXPRESSION, PolicyCondition.Operator.MATCHES, """
project.depends_on(org.hyades.policy.v1.Component{name: "acme-lib-a"})
project.depends_on(org.dependencytrack.policy.v1.Component{name: "acme-lib-a"})
""", PolicyViolation.Type.OPERATIONAL);

final var project = new Project();
Expand Down Expand Up @@ -613,7 +614,7 @@ public void testEvaluateProjectWithFuncProjectDependsOnComponent() {
public void testEvaluateProjectWithFuncComponentIsDependencyOfComponent() {
final var policy = qm.createPolicy("policy", Policy.Operator.ANY, Policy.ViolationState.FAIL);
qm.createPolicyCondition(policy, PolicyCondition.Subject.EXPRESSION, PolicyCondition.Operator.MATCHES, """
component.is_dependency_of(org.hyades.policy.v1.Component{name: "acme-lib-a"})
component.is_dependency_of(org.dependencytrack.policy.v1.Component{name: "acme-lib-a"})
""", PolicyViolation.Type.OPERATIONAL);

final var project = new Project();
Expand Down Expand Up @@ -863,6 +864,7 @@ public void issue2455() {
}

@Test
@Ignore // Un-ignore for manual profiling purposes.
public void testWithBloatedBom() throws Exception {
// Import all default objects (includes licenses and license groups).
new DefaultObjectGenerator().contextInitialized(null);
Expand Down

0 comments on commit 2b035e4

Please sign in to comment.