Codeception REST超时问题 [英] Codeception REST timeout issue

查看:75
本文介绍了Codeception REST超时问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试增加Codeception REST超时,但是似乎没有用。

I'm trying to increase the Codeception REST timeout, but it doesn't seem to be working.

这就是我所拥有的

class_name: ApiTester
modules:
    enabled:
        - \Helper\Api:
        - REST:
            depends: PhpBrowser
            timeout: 90

超时错误

[GuzzleHttp\Exception\ConnectException] cURL错误28:操作在接收到0个字节的30001毫秒后超时了

[GuzzleHttp\Exception\ConnectException] cURL error 28: Operation timed out after 30001 milliseconds with 0 bytes received

我在做什么错?

推荐答案

我也遇到了这个问题。这是我的验收通知

I had this problem too. This was my Fix

accepting.suite.yml

in acceptance.suite.yml

    # Codeception Test Suite Configuration

# suite for acceptance tests.
# perform tests in browser using the WebDriver or PhpBrowser.
# If you need both WebDriver and PHPBrowser tests - create a separate suite.

class_name: AcceptanceTester
modules:
    enabled:
        - PhpBrowser
        - REST
    config:
        REST:
            timeout: 90 # or 90000 the same result
        PhpBrowser:
            url: 'http://YOUR_URL_TO_YOUR_PUBLIC_FOLDER/public'
            curl:
                CURLOPT_TIMEOUT: 300 // in Seconds

我的问题是我只将带有 depends的REST放到了PhpBrowser中,但是您需要配置PhpBrowser设置超时时间。

My problem was that i put only the REST in it with "depends" to PhpBrowser but you need to configure the PhpBrowser to setup the Timeout.

我希望我能为我的英语不好而提供帮助和抱歉:)

I hope i could help and sorry for my bad english :)

亲切此致,
Thomas Meejumlong

Kind Regards, Thomas Meejumlong

这篇关于Codeception REST超时问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆