Search in sources :

Example 1 with ContextualHelpService

use of com.qcadoo.view.internal.api.ContextualHelpService in project qcadoo by qcadoo.

the class AbstractPatternTest method getComponentDefinition.

public ComponentDefinition getComponentDefinition(final String name, final String fieldPath, final String sourceFieldPath, final ContainerPattern parent, final ViewDefinition viewDefinition) {
    ComponentDefinition componentDefinition = new ComponentDefinition();
    componentDefinition.setName(name);
    componentDefinition.setFieldPath(fieldPath);
    componentDefinition.setSourceFieldPath(sourceFieldPath);
    componentDefinition.setParent(parent);
    TranslationService translationService = mock(TranslationService.class);
    componentDefinition.setTranslationService(translationService);
    ContextualHelpService contextualHelpService = mock(ContextualHelpService.class);
    componentDefinition.setContextualHelpService(contextualHelpService);
    if (viewDefinition != null) {
        componentDefinition.setViewDefinition(viewDefinition);
    } else {
        componentDefinition.setViewDefinition(mock(InternalViewDefinition.class));
    }
    return componentDefinition;
}
Also used : TranslationService(com.qcadoo.localization.api.TranslationService) InternalViewDefinition(com.qcadoo.view.internal.api.InternalViewDefinition) ContextualHelpService(com.qcadoo.view.internal.api.ContextualHelpService) ComponentDefinition(com.qcadoo.view.internal.ComponentDefinition)

Aggregations

TranslationService (com.qcadoo.localization.api.TranslationService)1 ComponentDefinition (com.qcadoo.view.internal.ComponentDefinition)1 ContextualHelpService (com.qcadoo.view.internal.api.ContextualHelpService)1 InternalViewDefinition (com.qcadoo.view.internal.api.InternalViewDefinition)1