@Test
public void approveArtifact(){

    final DbArtifact artifactWithLicense = new DbArtifact();
    final DbLicense license = new DbLicense();
    license.setName("licenseName");
    artifactWithLicense.addLicense(license);
    final DbArtifact artifactWithoutLicense = new DbArtifact();
    HasLicenseFilter filter = new HasLicenseFilter(true);
    assertTrue(filter.filter(artifactWithLicense));
    assertFalse(filter.filter(artifactWithoutLicense));
    filter = new HasLicenseFilter(false);
    assertFalse(filter.filter(artifactWithLicense));
    assertTrue(filter.filter(artifactWithoutLicense));
}