use of org.hisp.dhis.actions.metadata.TrackedEntityAttributeActions in project dhis2-core by dhis2.
the class AnalyticsDimensionsTest method beforeAll.
@BeforeAll
public void beforeAll() {
trackedEntityAttributeActions = new TrackedEntityAttributeActions();
programActions = new ProgramActions();
analyticsEnrollmentsActions = new AnalyticsEnrollmentsActions();
analyticsEventActions = new AnalyticsEventActions();
}
use of org.hisp.dhis.actions.metadata.TrackedEntityAttributeActions in project dhis2-core by dhis2.
the class EnrollmentAttributeTests method beforeEach.
@BeforeEach
public void beforeEach() {
teaAttributeActions = new TrackedEntityAttributeActions();
programActions = new ProgramActions();
loginActions.loginAsAdmin();
programId = programActions.createTrackerProgram(Constants.TRACKED_ENTITY_TYPE, Constants.ORG_UNIT_IDS).extractUid();
setupAttributes();
}
use of org.hisp.dhis.actions.metadata.TrackedEntityAttributeActions in project dhis2-core by dhis2.
the class TeiValidationTests method setupData.
private void setupData() {
TrackedEntityAttributeActions trackedEntityAttributeActions = new TrackedEntityAttributeActions();
ProgramActions programActions = new ProgramActions();
TrackedEntityTypeActions trackedEntityTypeActions = new TrackedEntityTypeActions();
trackedEntityType = trackedEntityTypeActions.create();
// create attributes
uniqueTetAttribute = trackedEntityAttributeActions.create("TEXT", true);
mandatoryTetAttribute = trackedEntityAttributeActions.create("TEXT");
mandatoryProgramAttribute = trackedEntityAttributeActions.create("TEXT");
attributeWithOptionSet = trackedEntityAttributeActions.createOptionSetAttribute("ZGkmoWb77MW");
trackedEntityTypeActions.addAttribute(trackedEntityType, mandatoryTetAttribute, true);
trackedEntityTypeActions.addAttribute(trackedEntityType, attributeWithOptionSet, false);
trackedEntityTypeActions.addAttribute(trackedEntityType, uniqueTetAttribute, false);
// create a program
program = programActions.createTrackerProgram(trackedEntityType, Constants.ORG_UNIT_IDS).extractUid();
programActions.addAttribute(program, mandatoryProgramAttribute, true);
}
Aggregations