Laravel 5.1 PHPUnit 503 错误

Laravel 5.1 PHPUnit 503 error

目前遇到无缘无故返回 503 错误的测试。 运行 Laravel 5.1 和最新的 PHPUnit。

测试:

$this->call('GET', '/about');
$this->assertResponseStatus(200);

失败,因为它 returns 503 错误,其他测试(类似 GET 调用)通过。

如果我 dd($this->call()) 我可以看到返回了整个 html 响应,但仍然附加了 503 错误。日志中也没有错误。页面在浏览器中加载正常,没有 503 错误。

编辑:

Route::group(array('after' => 'cache:1440'), function() {
    Route::get('about', 'HomeController@showAbout');
}

edit2:

dd($this->call('GET', '/about'));

产量满 html+

version: "1.1"
statusCode: 503
statusText: "Service Unavailable"
charset: null

composer.json

{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
    "php": ">=5.5.9",
    "laravel/framework": "5.1.*",
    "laravelcollective/html": "~5.0",
    "intervention/image": "dev-master",
    "watson/sitemap": "2.0.*",
    "rap2hpoutre/laravel-log-viewer": "dev-master",
    "barryvdh/laravel-httpcache": "0.2.x@dev",
    "guzzlehttp/guzzle": "~5.3|~6.0"
},
"require-dev": {
    "fzaninotto/faker": "~1.4",
    "mockery/mockery": "0.9.*",
    "phpunit/phpunit": "~4.0",
    "phpspec/phpspec": "~2.1"
},
"autoload": {
    "classmap": [
        "database",
        "app/Http/Controllers",
        "app/Models",
        "app/Helpers"
    ],
    "psr-4": {
        "App\": "app/"
    }
},
"autoload-dev": {
    "classmap": [
        "tests/TestCase.php"
    ]
},
"scripts": {
    "post-install-cmd": [
        "php artisan clear-compiled",
        "php artisan optimize"
    ],
    "post-update-cmd": [
        "php artisan clear-compiled",
        "php artisan optimize"
    ],
    "post-root-package-install": [
        "php -r \"copy('.env.example', '.env');\""
    ],
    "post-create-project-cmd": [
        "php artisan key:generate"
    ]
},
"config": {
    "preferred-install": "dist"
},
"minimum-stability": "dev",
"prefer-stable": true
}

好吧,由于某种原因,我发现问题是刷新和清除缓存对 barryvdh\laravel-httpcache 库不起作用,我不得不手动删除 storage/httpcache

下的所有内容