src/test/java/org/codelibs/fess/it/admin/CrawlerLogTests.java
private static void createWebConfig() {
        final Map<String, Object> requestBody = new HashMap<>();
        final String urls = "http://example.com" + "\n" + "http://failure.url";
        requestBody.put("name", NAME_PREFIX + "WebConfig");
        requestBody.put("urls", urls);
        requestBody.put("user_agent", "Mozilla/5.0");
        requestBody.put("depth", 1);
        requestBody.put("num_of_thread", 1);
        requestBody.put("interval_time", 1000);
        requestBody.put("boost", 100);
        requestBody.put("available", true);
        requestBody.put("sort_order", 0);

        checkMethodBase(requestBody).put("/api/admin/webconfig/setting").then().body("response.created", equalTo(true))
                .body("response.status", equalTo(0));
    }
/**
     * Methods for a Web Crawling Job
     * */
Methods for a Web Crawling Job
Methods for a Web Crawling Job
private static void createWebConfig() {
        final Map<String, Object> requestBody = new HashMap<>();
        final String urls = "http://example.com" + "\n" + "http://failure.url";
        requestBody.put("name", NAME_PREFIX + "WebConfig");
        requestBody.put("urls", urls);
        requestBody.put("user_agent", "Mozilla/5.0");
        requestBody.put("depth", 1);
        requestBody.put("num_of_thread", 1);
        requestBody.put("interval_time", 1000);
        requestBody.put("boost", 100);
        requestBody.put("available", true);
        requestBody.put("sort_order", 0);
        checkMethodBase(requestBody).put("/api/admin/webconfig/setting").then().body("response.created", equalTo(true))
                .body("response.status", equalTo(0));
    }
private static void createWebConfig ( ) { final Map < String , Object > requestBody = new HashMap < > ( ) ; final String urls = "http://example.com" + "\n" + "http://failure.url" ; requestBody . put ( "name" , NAME_PREFIX + "WebConfig" ) ; requestBody . put ( "urls" , urls ) ; requestBody . put ( "user_agent" , "Mozilla/5.0" ) ; requestBody . put ( "depth" , 1 ) ; requestBody . put ( "num_of_thread" , 1 ) ; requestBody . put ( "interval_time" , 1000 ) ; requestBody . put ( "boost" , 100 ) ; requestBody . put ( "available" , true ) ; requestBody . put ( "sort_order" , 0 ) ; checkMethodBase ( requestBody ) . put ( "/api/admin/webconfig/setting" ) . then ( ) . body ( "response.created" , equalTo ( true ) ) . body ( "response.status" , equalTo ( 0 ) ) ; }
Methods for a Web Crawling Job
Methods for a Web Crawling Job