Search in sources :

Example 1 with FixedAssetForTesting

use of org.estatio.module.asset.dom.FixedAssetForTesting in project estatio by estatio.

the class LandRegister_title_Test method setUp.

@Before
public void setUp() throws Exception {
    cr = new LandRegister();
    cr.setContainer(mockContainer);
    subject = new FixedAssetForTesting();
    type = new FixedAssetRegistrationType();
    cr.setType(type);
    cr.setSubject(subject);
}
Also used : FixedAssetRegistrationType(org.estatio.module.asset.dom.registration.FixedAssetRegistrationType) FixedAssetForTesting(org.estatio.module.asset.dom.FixedAssetForTesting) Before(org.junit.Before)

Example 2 with FixedAssetForTesting

use of org.estatio.module.asset.dom.FixedAssetForTesting in project estatio by estatio.

the class LeaseRepository_Test method setup.

@Before
public void setup() {
    asset = new FixedAssetForTesting();
    property = new Property();
    leaseRepository = new LeaseRepository() {

        @Override
        protected <T> T uniqueMatch(Query<T> query) {
            finderInteraction = new FinderInteraction(query, FinderMethod.UNIQUE_MATCH);
            return (T) new Lease();
        }

        @Override
        protected List<Lease> allInstances() {
            finderInteraction = new FinderInteraction(null, FinderMethod.ALL_INSTANCES);
            return null;
        }

        @Override
        protected <T> List<T> allMatches(Query<T> query) {
            finderInteraction = new FinderInteraction(query, FinderMethod.ALL_MATCHES);
            return null;
        }
    };
    leaseRepository.clockService = new ClockService();
}
Also used : ClockService(org.apache.isis.applib.services.clock.ClockService) FixedAssetForTesting(org.estatio.module.asset.dom.FixedAssetForTesting) List(java.util.List) Property(org.estatio.module.asset.dom.Property) FinderInteraction(org.incode.module.unittestsupport.dom.repo.FinderInteraction) Before(org.junit.Before)

Aggregations

FixedAssetForTesting (org.estatio.module.asset.dom.FixedAssetForTesting)2 Before (org.junit.Before)2 List (java.util.List)1 ClockService (org.apache.isis.applib.services.clock.ClockService)1 Property (org.estatio.module.asset.dom.Property)1 FixedAssetRegistrationType (org.estatio.module.asset.dom.registration.FixedAssetRegistrationType)1 FinderInteraction (org.incode.module.unittestsupport.dom.repo.FinderInteraction)1