Class SWTValidationUiServiceImpl_Test
- java.lang.Object
-
- org.eclipse.emfforms.internal.swt.core.ui.SWTValidationUiServiceImpl_Test
-
public class SWTValidationUiServiceImpl_Test extends java.lang.Object
Unit tests forSWTValidationUiServiceImpl
.- Author:
- Lucas Koehler
-
-
Constructor Summary
Constructors Constructor Description SWTValidationUiServiceImpl_Test()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
getValidationBackgroundColor()
Test that getValidationBackgroundColor(VElement, ViewModelContext) correctly delegates to getValidationBackgroundColor(Diagnostic, VElement, ViewModelContext) and that the latter correctly delegates to SWTValidationHelper.void
getValidationBackgroundColor_caching()
The service should cache icons by severity.void
getValidationBackgroundColor_emptyVDiagnostic()
If the VElement's VDiagnostic doesn't have any Diagnostics, it should be assumed that there is no validation error.void
getValidationBackgroundColor_nullDiagnostic()
If the given Diagnostic is null, it should be assumed that there is no validation error.void
getValidationBackgroundColor_nullVDiagnostic()
If the VElement doesn't have a VDiagnostic, it should be assumed that there is no validation error.void
getValidationForegroundColor()
Test that getValidationForegroundColor(VElement, ViewModelContext) correctly delegates to getValidationForegroundColor(Diagnostic, VElement, ViewModelContext) and that the latter correctly delegates to SWTValidationHelper.void
getValidationForegroundColor_caching()
The service should cache icons by severity.void
getValidationForegroundColor_emptyVDiagnostic()
If the VElement's VDiagnostic doesn't have any Diagnostics, it should be assumed that there is no validation error.void
getValidationForegroundColor_nullDiagnostic()
If the given Diagnostic is null, it should be assumed that there is no validation error.void
getValidationForegroundColor_nullVDiagnostic()
If the VElement doesn't have a VDiagnostic, it should be assumed that there is no validation error.void
getValidationIcon()
Test that getValidationIcon(VElement, ViewModelContext) correctly delegates to getValidationIcon(Diagnostic, VElement, ViewModelContext) and that the latter correctly delegates to SWTValidationHelper.void
getValidationIcon_caching()
The service should cache icons by severity.void
getValidationIcon_emptyVDiagnostic()
If the VElement's VDiagnostic doesn't have any Diagnostics, it should be assumed that there is no validation error.void
getValidationIcon_nullDiagnostic()
If the given Diagnostic is null, it should be assumed that there is no validation error.void
getValidationIcon_nullVDiagnostic()
If the VElement doesn't have a VDiagnostic, it should be assumed that there is no validation error.void
setUp()
-
-
-
Method Detail
-
setUp
public void setUp()
-
getValidationIcon
public void getValidationIcon()
Test that getValidationIcon(VElement, ViewModelContext) correctly delegates to getValidationIcon(Diagnostic, VElement, ViewModelContext) and that the latter correctly delegates to SWTValidationHelper.
-
getValidationIcon_nullVDiagnostic
public void getValidationIcon_nullVDiagnostic()
If the VElement doesn't have a VDiagnostic, it should be assumed that there is no validation error.
-
getValidationIcon_emptyVDiagnostic
public void getValidationIcon_emptyVDiagnostic()
If the VElement's VDiagnostic doesn't have any Diagnostics, it should be assumed that there is no validation error.
-
getValidationIcon_nullDiagnostic
public void getValidationIcon_nullDiagnostic()
If the given Diagnostic is null, it should be assumed that there is no validation error.
-
getValidationIcon_caching
public void getValidationIcon_caching()
The service should cache icons by severity.
-
getValidationForegroundColor
public void getValidationForegroundColor()
Test that getValidationForegroundColor(VElement, ViewModelContext) correctly delegates to getValidationForegroundColor(Diagnostic, VElement, ViewModelContext) and that the latter correctly delegates to SWTValidationHelper.
-
getValidationForegroundColor_nullVDiagnostic
public void getValidationForegroundColor_nullVDiagnostic()
If the VElement doesn't have a VDiagnostic, it should be assumed that there is no validation error.
-
getValidationForegroundColor_emptyVDiagnostic
public void getValidationForegroundColor_emptyVDiagnostic()
If the VElement's VDiagnostic doesn't have any Diagnostics, it should be assumed that there is no validation error.
-
getValidationForegroundColor_nullDiagnostic
public void getValidationForegroundColor_nullDiagnostic()
If the given Diagnostic is null, it should be assumed that there is no validation error.
-
getValidationForegroundColor_caching
public void getValidationForegroundColor_caching()
The service should cache icons by severity.
-
getValidationBackgroundColor
public void getValidationBackgroundColor()
Test that getValidationBackgroundColor(VElement, ViewModelContext) correctly delegates to getValidationBackgroundColor(Diagnostic, VElement, ViewModelContext) and that the latter correctly delegates to SWTValidationHelper.
-
getValidationBackgroundColor_nullVDiagnostic
public void getValidationBackgroundColor_nullVDiagnostic()
If the VElement doesn't have a VDiagnostic, it should be assumed that there is no validation error.
-
getValidationBackgroundColor_emptyVDiagnostic
public void getValidationBackgroundColor_emptyVDiagnostic()
If the VElement's VDiagnostic doesn't have any Diagnostics, it should be assumed that there is no validation error.
-
getValidationBackgroundColor_nullDiagnostic
public void getValidationBackgroundColor_nullDiagnostic()
If the given Diagnostic is null, it should be assumed that there is no validation error.
-
getValidationBackgroundColor_caching
public void getValidationBackgroundColor_caching()
The service should cache icons by severity.
-
-