當前位置: 首頁>>代碼示例>>Java>>正文


Java RestAssured.enableLoggingOfRequestAndResponseIfValidationFails方法代碼示例

本文整理匯總了Java中io.restassured.RestAssured.enableLoggingOfRequestAndResponseIfValidationFails方法的典型用法代碼示例。如果您正苦於以下問題:Java RestAssured.enableLoggingOfRequestAndResponseIfValidationFails方法的具體用法?Java RestAssured.enableLoggingOfRequestAndResponseIfValidationFails怎麽用?Java RestAssured.enableLoggingOfRequestAndResponseIfValidationFails使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在io.restassured.RestAssured的用法示例。


在下文中一共展示了RestAssured.enableLoggingOfRequestAndResponseIfValidationFails方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: Resource

import io.restassured.RestAssured; //導入方法依賴的package包/類
public Resource(HashMap<CommsRouterResource, String> state) {
  RestAssured.enableLoggingOfRequestAndResponseIfValidationFails();
  java.util.Map<String, String> env = System.getenv();

  if (System.getProperty("autHost") == null) {
    String host = env.get("AUT_HOST");
    if (host != null) {
      RestAssured.baseURI = host;
    } else {
      RestAssured.baseURI = "http://localhost:8080";
    }
  } else {
    // you can specify it using -DautHost=http://localhost:8080
    RestAssured.baseURI = System.getProperty("autHost");
  }
  RestAssured.basePath = "/comms-router-web/api";
  this.state = state;
}
 
開發者ID:Nexmo,項目名稱:comms-router,代碼行數:19,代碼來源:Resource.java

示例2: startApp

import io.restassured.RestAssured; //導入方法依賴的package包/類
@BeforeClass
public static void startApp() {

    RestAssured.config = RestAssured.config().sessionConfig(new SessionConfig().sessionIdName("APPSESSIONID"));
    RestAssured.enableLoggingOfRequestAndResponseIfValidationFails();
    RestAssured.port = 9090;

    Thread thread = new Thread(() -> {
        try {
            JettyApp.main(new String[]{Integer.toString(RestAssured.port)});
        } catch (Exception e) {
            e.printStackTrace();
        }
    });
    thread.start();
    // give the app time to spin up
    try {
        Thread.sleep(3000);
    } catch (InterruptedException ex) {
        Thread.currentThread().interrupt();
    }

}
 
開發者ID:wmluke,項目名稱:pipes,代碼行數:24,代碼來源:ExampleAppWithJettyTest.java

示例3: initClass

import io.restassured.RestAssured; //導入方法依賴的package包/類
@BeforeAll
public static void initClass(){
    restController.setControllerPort(0);
    restController.startTheControllerServer();

    RestAssured.baseURI = "http://localhost";
    RestAssured.port = restController.getControllerServerPort();
    RestAssured.basePath = "/controller/api";
    RestAssured.enableLoggingOfRequestAndResponseIfValidationFails();
}
 
開發者ID:EMResearch,項目名稱:EvoMaster,代碼行數:11,代碼來源:SutControllerTest.java

示例4: setupSuite

import io.restassured.RestAssured; //導入方法依賴的package包/類
@BeforeSuite
public void setupSuite() {
    LOGGER.info("Starting application...");
    application.startServer();
    RestAssured.enableLoggingOfRequestAndResponseIfValidationFails();
}
 
開發者ID:carlomorelli,項目名稱:muon-app,代碼行數:7,代碼來源:BaseTest.java

示例5: setXAuthIntegrationTest

import io.restassured.RestAssured; //導入方法依賴的package包/類
@Before
public void setXAuthIntegrationTest() {
    RestAssured.port = port;
    RestAssured.config().redirect(RedirectConfig.redirectConfig().followRedirects(false));
    RestAssured.enableLoggingOfRequestAndResponseIfValidationFails();
}
 
開發者ID:AreaFiftyLAN,項目名稱:lancie-api,代碼行數:7,代碼來源:XAuthIntegrationTest.java


注:本文中的io.restassured.RestAssured.enableLoggingOfRequestAndResponseIfValidationFails方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。