@Test public void test_should_convert_from_contract_to_domain() { City cityContract = City.builder() .name("Bengaluru") .localName("localname") .districtCode("districtcode") .districtName("districtname") .regionName("regionname") .longitude(35.456) .latitude(75.443) .shapeFileLocation("shapeFileLocation") .captcha("captcha") .build(); org.egov.tenant.domain.model.City expectedCityModel = org.egov.tenant.domain.model.City.builder() .name("Bengaluru") .localName("localname") .districtCode("districtcode") .districtName("districtname") .regionName("regionname") .longitude(35.456) .latitude(75.443) .shapeFileLocation("shapeFileLocation") .captcha("captcha") .build(); org.egov.tenant.domain.model.City domain = cityContract.toDomain(); assertThat(domain).isEqualTo(expectedCityModel); }
@JsonIgnore public org.egov.tenant.domain.model.City toDomain() { return org.egov.tenant.domain.model.City.builder() .name(name) .localName(localName) .districtCode(districtCode) .districtName(districtName) .ulbGrade(ulbGrade) .regionName(regionName) .longitude(longitude) .latitude(latitude) .shapeFileLocation(shapeFileLocation) .captcha(captcha) .code(code) .build(); }
City { @JsonIgnore public org.egov.tenant.domain.model.City toDomain() { return org.egov.tenant.domain.model.City.builder() .name(name) .localName(localName) .districtCode(districtCode) .districtName(districtName) .ulbGrade(ulbGrade) .regionName(regionName) .longitude(longitude) .latitude(latitude) .shapeFileLocation(shapeFileLocation) .captcha(captcha) .code(code) .build(); } }
City { @JsonIgnore public org.egov.tenant.domain.model.City toDomain() { return org.egov.tenant.domain.model.City.builder() .name(name) .localName(localName) .districtCode(districtCode) .districtName(districtName) .ulbGrade(ulbGrade) .regionName(regionName) .longitude(longitude) .latitude(latitude) .shapeFileLocation(shapeFileLocation) .captcha(captcha) .code(code) .build(); } City(org.egov.tenant.domain.model.City city); }
City { @JsonIgnore public org.egov.tenant.domain.model.City toDomain() { return org.egov.tenant.domain.model.City.builder() .name(name) .localName(localName) .districtCode(districtCode) .districtName(districtName) .ulbGrade(ulbGrade) .regionName(regionName) .longitude(longitude) .latitude(latitude) .shapeFileLocation(shapeFileLocation) .captcha(captcha) .code(code) .build(); } City(org.egov.tenant.domain.model.City city); @JsonIgnore org.egov.tenant.domain.model.City toDomain(); }
City { @JsonIgnore public org.egov.tenant.domain.model.City toDomain() { return org.egov.tenant.domain.model.City.builder() .name(name) .localName(localName) .districtCode(districtCode) .districtName(districtName) .ulbGrade(ulbGrade) .regionName(regionName) .longitude(longitude) .latitude(latitude) .shapeFileLocation(shapeFileLocation) .captcha(captcha) .code(code) .build(); } City(org.egov.tenant.domain.model.City city); @JsonIgnore org.egov.tenant.domain.model.City toDomain();  }