Skip to content

Instantly share code, notes, and snippets.

View ivange94's full-sized avatar
🏠
Working from home

Larry ivange94

🏠
Working from home
View GitHub Profile
import * as mockOpenmrsModuleConfig from '../../__mocks__/openmrs-esm-module-config.mock';
let mockOpenmrsConfig = {
persontAttributeSections: [
{
name: 'additionalPersonAttributesSectionHeader',
personAttributes: [
{
name: 'telephoneNumber',
label: 'phoneNumber',
// Replace [line 182](https://github.com/openmrs/openmrs-esm-patient-registration/blob/master/src/patient-registration/patient-registration.component.tsx#L182) with
setValidationSchema(validationSchema.concat(addressValidationSchemaTmp));
// Delete https://github.com/openmrs/openmrs-esm-patient-registration/blob/master/src/patient-registration/patient-registration.component.tsx#L86
//And in the form component replace
Replace [line 182](https://github.com/openmrs/openmrs-esm-patient-registration/blob/master/src/patient-registration/patient-registration.component.tsx#L182) with
```javascript
setValidationSchema(validationSchema.concat(addressValidationSchemaTmp));
```
Delete https://github.com/openmrs/openmrs-esm-patient-registration/blob/master/src/patient-registration/patient-registration.component.tsx#L86
And in the form component replace
Replace [line 182](https://github.com/openmrs/openmrs-esm-patient-registration/blob/master/src/patient-registration/patient-registration.component.tsx#L182) with
```javascript
setValidationSchema(validationSchema.concat(addressValidationSchemaTmp));
```
Delete https://github.com/openmrs/openmrs-esm-patient-registration/blob/master/src/patient-registration/patient-registration.component.tsx#L86
And in the form component replace
// Second part of the report: obs summary row
{
DataSetRow row = dataSet.getDataSets().get("Obs Summary").iterator().next();
assertThat(row, is(notNullValue()));
Map<String, Object> reportDataMap = row.getColumnValuesByKey();
Set<String> colNames = new HashSet<>(reportDataMap.keySet());
colNames.remove(OutpatientConsultationReportManager.col12);
{
Running org.openmrs.module.radiology.modality.RadiologyModalityEditorComponentTest
Tests run: 6, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 13.742 sec <<< FAILURE!
setAsText_shouldReturnNullForEmptyText(org.openmrs.module.radiology.modality.RadiologyModalityEditorComponentTest) Time elapsed: 0.006 sec <<< ERROR!
java.lang.IllegalStateException: Failed to load ApplicationContext
at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:124)
at org.springframework.test.context.support.DefaultTestContext.getApplicationContext(DefaultTestContext.java:83)
at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.injectDependencies(DependencyInjectionTestExecutionListener.java:117)
at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.prepareTestInstance(DependencyInjectionTestExecutionListener.java:83)
at org.springframework.test.context.TestContextManager.prepareTestInsta
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.web.servlet.view.ContentNegotiatingViewResolver#0' defined in URL [file:/Users/ivange/workspace/lh-projects/lh-toolkit/web/target/classes/openmrs-servlet.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'mediaTypes' of bean class [org.springframework.web.servlet.view.ContentNegotiatingViewResolver]: Bean property 'mediaTypes' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] Reporting
[INFO] Reporting API
[INFO] reporting Module api 1.9
[INFO] reporting Module api 2.0
[INFO] reporting API Tests
[INFO] Reporting OMOD
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] Reporting
[INFO] Reporting API
[INFO] reporting Module api 1.9
[INFO] reporting Module api 2.0
[INFO] reporting API Tests
[INFO] Reporting OMOD