【问题标题】:Can I use last Codeception version with PHPUnit 5?我可以将最后一个 Codeception 版本与 PHPUnit 5 一起使用吗?
【发布时间】:2019-05-15 21:15:59
【问题描述】:

我正在使用 PHP 5.6 进行项目,当我尝试使用 Codeception 进行单元测试时,该项目无法运行,因为 Codeception 使用 PHPUnit 7,因此使用 PHP 7。 有没有办法强制使用 PHPUnit 5 和 Codeception 或其他方式来解决这个问题?

【问题讨论】:

  • 我注意到 PHP 5.6 将在 16 天内结束生命周期。是时候升级了。 php.net/supported-versions.php
  • Codeception 支持 PHP 5.4+。你是怎么安装的?

标签: php phpunit codeception php-5.6


【解决方案1】:

那么您应该开始将您的项目更新到 PHP 7,因为 PHP 5.6 将于 2019 年 1 月 1 日结束生命周期。现在大多数库都是为更新版本开发的。还有一些依赖依赖于 PHP 7。

因此,出于安全原因以及可以在较新版本中使用的更好功能,我真的建议您开始更新您的项目。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2017-02-01
    • 2018-08-03
    • 2017-07-26
    • 2014-09-08
    • 2011-05-26
    • 1970-01-01
    • 2023-03-21
    相关资源
    最近更新 更多