Skip to content

Commit

Permalink
Fixed failing unit tests.
Browse files Browse the repository at this point in the history
Signed-off-by: Juergen Fickel <juergen.fickel@bosch.io>
  • Loading branch information
Juergen Fickel authored and Stefan Maute committed Jul 1, 2020
1 parent e93f795 commit c426f59
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
Expand Up @@ -21,14 +21,15 @@
import org.eclipse.ditto.model.base.acks.AcknowledgementLabel;
import org.eclipse.ditto.model.base.entity.id.EntityIdWithType;
import org.eclipse.ditto.model.base.headers.DittoHeaders;
import org.eclipse.ditto.model.things.ThingId;
import org.junit.Test;

import nl.jqno.equalsverifier.EqualsVerifier;

/**
* Unit tests for {@link ImmutableAcknowledgementRequestHandle}.
*/
public class ImmutableAcknowledgementRequestHandleTest {
public final class ImmutableAcknowledgementRequestHandleTest {

@Test
public void assertImmutability() {
Expand All @@ -39,8 +40,14 @@ public void assertImmutability() {

@Test
public void testHashCodeAndEquals() {
final ThingId red = ThingId.generateRandom();
final ThingId black = ThingId.generateRandom();

EqualsVerifier.forClass(ImmutableAcknowledgementRequestHandle.class)
.usingGetClass()
.withIgnoredFields("acknowledgementPublisher")
.withPrefabValues(EntityIdWithType.class, red, black)
.verify();
}

}
Expand Up @@ -23,6 +23,7 @@
import org.eclipse.ditto.json.JsonValue;
import org.eclipse.ditto.model.base.entity.id.EntityIdWithType;
import org.eclipse.ditto.model.base.headers.DittoHeaders;
import org.eclipse.ditto.model.things.ThingId;
import org.junit.Test;

import nl.jqno.equalsverifier.EqualsVerifier;
Expand All @@ -41,8 +42,13 @@ public void assertImmutability() {

@Test
public void testHashCodeAndEquals() {
final ThingId red = ThingId.generateRandom();
final ThingId black = ThingId.generateRandom();

EqualsVerifier.forClass(ImmutableChange.class)
.usingGetClass()
.withIgnoredFields("acknowledgementPublisher")
.withPrefabValues(EntityIdWithType.class, red, black)
.verify();
}

Expand Down

0 comments on commit c426f59

Please sign in to comment.