Commit e2b317d8 authored by Raimbek Egemberdiev's avatar Raimbek Egemberdiev

merged dev

parent 663bb459
......@@ -21,16 +21,16 @@ import java.util.Set;
* @author raimbek
* @since 09.11.2016
*/
public class AsFormProvider {
public class AsFormService {
private RestHttpQuery restHttpQuery;
private AsFormProvider(QueryContext context) {
private AsFormService(QueryContext context) {
this.restHttpQuery = new RestHttpQuery(context);
}
public static AsFormProvider newInstance(QueryContext context) {
return new AsFormProvider(context);
public static AsFormService newInstance(QueryContext context) {
return new AsFormService(context);
}
public List<AdvancedSearchResult> advancedSearch(AdvancedSearchParams searchParams) throws IOException {
......
......@@ -17,7 +17,7 @@ import java.util.List;
* @author raimbek
* @since 09.11.2016
*/
public class AsFormProviderTest {
public class AsFormServiceTest {
String expectedTextInputValue = "value_1";
String expectedNumericInputValue = "value_2";
......@@ -33,7 +33,7 @@ public class AsFormProviderTest {
String expectedTableInputValueB2 = "table_input_b2";
TestForm testForm;
AsFormProvider asFormProvider;
AsFormService asFormService;
@BeforeClass
public void createAsfWrapper() throws IOException {
......@@ -63,8 +63,8 @@ public class AsFormProviderTest {
@Test
public void testQuery() throws IOException {
asFormProvider = AsFormProvider.newInstance(new QueryContext("http://192.168.0.143:8080/Synergy", "NppAdmin", "123456"));
TestForm fetch = asFormProvider.fetch(TestForm.class, "2ae95419-af0e-4017-bad9-ff527591ef02");
asFormService = AsFormService.newInstance(new QueryContext("http://192.168.0.143:8080/Synergy", "NppAdmin", "123456"));
TestForm fetch = asFormService.fetch(TestForm.class, "2ae95419-af0e-4017-bad9-ff527591ef02");
System.out.println();
}
......@@ -109,7 +109,7 @@ public class AsFormProviderTest {
@Test
public void toAsfData() {
AsFormWrapper asFormWrapper = asFormProvider.toAsfData(testForm);
AsFormWrapper asFormWrapper = asFormService.toAsfData(testForm);
AsFormData textInput = asFormWrapper.getData("text_input");
Assert.assertEquals(textInput.getType(), ComponentTypes.TEXT_BOX);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment