【发布时间】:2018-08-05 17:50:32
【问题描述】:
我正在尝试使用 laravel 进行单元测试,但出现以下错误。我不必测试该功能。在我的编辑器中,我正确地看到了对类的引用,但是 phpunit 找不到它。
Error: Class 'GoCardlessCheck' not found
我的测试是这样的
use Illuminate\Foundation\Testing\WithoutMiddleware;
use Illuminate\Foundation\Testing\DatabaseMigrations;
use Illuminate\Foundation\Testing\DatabaseTransactions;
use PHPUnit\Framework\TestCase;
class GoCardlessTest extends TestCase
{
/**
* A basic test example.
*
* @return void
*/
public function testExample()
{
$acc = new GoCardlessCheck();
$acc->CheckAccount('bob','mould','909090','57-77-90');
}
}
【问题讨论】:
-
已经导入类
GoCardlessCheck? -
导入了课程?你什么意思?