【问题标题】:Call failed after 702 milliseconds702 毫秒后调用失败
【发布时间】:2017-08-11 15:56:36
【问题描述】:

我在运行第一个脚本时看到以下错误。

com.intuit.karate.exception.KarateException:http 调用在 702 毫秒后失败,网址为:https://qa.myorg.intVersion

这是我的功能文件。

Feature: Test feature 
Scenario: Verify my service is up and running
Given url 'https://qa.myorg.int\Version'
When method get
Then status 200

这是我的 Java 文件:

package examples
import org.junit.runner.RunWith
import com.intuit.karate.junit4.Karate
@RunWith(Karate.class)
public class jenkinsTest {
}

我在调试模式下手动等待了很长时间。尽管如此,我还是看到了下面的错误,并且没有将 HTML 报告加载到目标文件夹中。 (我只看到目标文件夹下的 Karate.log。)

11:36:23.751 [main] 错误 com.intuit.karate - javax.net.ssl.SSLHandshakeException:sun.security.validator.ValidatorException:PKIX 路径构建失败:sun.security.provider.certpath.SunCertPathBuilderException:无法为了找到请求目标的有效认证路径,http 调用在 271489 毫秒后失败,网址为:https://qa.myorg.int/Version

我该如何解决?

【问题讨论】:

    标签: karate


    【解决方案1】:

    请参阅configure 文档以了解 SSL。试试这个:

    Feature: Test feature
    
    Background:
    * configure ssl = true
    
    Scenario: Verify my service is up and running
    Given url 'https://qa.myorg.int/Version'
    When method get
    Then status 200
    

    【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2017-02-02
    • 1970-01-01
    • 2015-01-10
    • 2021-12-07
    • 2023-04-10
    • 2017-05-18
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多