### Question:
ChargingLine implements Importable { boolean discardedOrAggregatedOrApplied() { if (getImportStatus() == ImportStatus.DISCARDED || getImportStatus() == ImportStatus.AGGREGATED || getApplied() != null) { return true; } return false; } ChargingLine(); String title(); @PropertyLayout(hidden = Where.PARENTED_TABLES) Lease getLease(); LeaseItem getLeaseItem(); @Action(semantics = SemanticsOf.NON_IDEMPOTENT) ImportStatus apply(); boolean hideApply(); @Action(semantics = SemanticsOf.IDEMPOTENT) ChargingLine discard(); boolean hideDiscard(); @Action(semantics = SemanticsOf.IDEMPOTENT) ChargingLine noUpdate(); boolean hideNoUpdate(); @Programmatic List<Object> importChargingLine(final boolean nonDiscardedOnly); @Override @Programmatic List<Object> importData(final Object previousRow);  }### Answer:
@Test public void discarded_or_applied() throws Exception { ChargingLine line = new ChargingLine(); Assertions.assertThat(line.discardedOrAggregatedOrApplied()).isFalse(); line.setImportStatus(ImportStatus.DISCARDED); Assertions.assertThat(line.discardedOrAggregatedOrApplied()).isTrue(); line.setImportStatus(ImportStatus.LEASE_ITEM_CREATED); Assertions.assertThat(line.discardedOrAggregatedOrApplied()).isFalse(); line.setImportStatus(null); line.setApplied(new LocalDate()); Assertions.assertThat(line.discardedOrAggregatedOrApplied()).isTrue(); line.setImportStatus(ImportStatus.LEASE_ITEM_CREATED); line.setApplied(new LocalDate()); Assertions.assertThat(line.discardedOrAggregatedOrApplied()).isTrue(); line.setImportStatus(ImportStatus.DISCARDED); line.setApplied(new LocalDate()); Assertions.assertThat(line.discardedOrAggregatedOrApplied()).isTrue(); }