### Question:
ProposerSlashing implements Merkleizable, SimpleOffsetSerializable, SSZContainer { @Override public boolean equals(Object obj) { if (Objects.isNull(obj)) { return false; } if (this == obj) { return true; } if (!(obj instanceof ProposerSlashing)) { return false; } ProposerSlashing other = (ProposerSlashing) obj; return Objects.equals(this.getHeader_1(), other.getHeader_1()) && Objects.equals(this.getHeader_2(), other.getHeader_2()); } ProposerSlashing(SignedBeaconBlockHeader header_1, SignedBeaconBlockHeader header_2); @Override int getSSZFieldCount(); @Override List<Bytes> get_fixed_parts(); @Override int hashCode(); @Override boolean equals(Object obj); SignedBeaconBlockHeader getHeader_1(); SignedBeaconBlockHeader getHeader_2(); @Override Bytes32 hash_tree_root(); static final int SSZ_FIELD_COUNT; }### Answer:
@Test void equalsReturnsFalseWhenProposalData1IsDifferent() { SignedBeaconBlockHeader otherProposal1 = dataStructureUtil.randomSignedBeaconBlockHeader(); while (Objects.equals(otherProposal1, proposal1)) { otherProposal1 = dataStructureUtil.randomSignedBeaconBlockHeader(); } ProposerSlashing testProposerSlashing = new ProposerSlashing(otherProposal1, proposal2); assertNotEquals(proposerSlashing, testProposerSlashing); }
@Test void equalsReturnsFalseWhenProposalData2IsDifferent() { SignedBeaconBlockHeader otherProposal2 = dataStructureUtil.randomSignedBeaconBlockHeader(); while (Objects.equals(otherProposal2, proposal2)) { otherProposal2 = dataStructureUtil.randomSignedBeaconBlockHeader(); } ProposerSlashing testProposerSlashing = new ProposerSlashing(proposal1, otherProposal2); assertNotEquals(proposerSlashing, testProposerSlashing); }