不支持驱动程序[google]

时间:2015-02-06 15:07:06

标签: testing laravel codeception

我有一个使用google Auth授权用户的应用,我尝试使用代码框架进行一些功能测试,但是当我尝试运行功能测试时出现以下错误

[InvalidArgumentException]
Driver [google] not supported.

在代码中定义Google Auth是否有问题,或者可能是通过它? ,它在我的应用程序中运行得很好但是它没有在测试中工作 这是我的Auth配置文件

返回数组(

/*
|--------------------------------------------------------------------------
| Default Authentication Driver
|--------------------------------------------------------------------------
|
| This option controls the authentication driver that will be utilized.
| This driver manages the retrieval and authentication of the users
| attempting to get access to protected areas of your application.
|
| Supported: "database", "eloquent"
|
*/

'driver' => 'google',

/*
|--------------------------------------------------------------------------
| Authentication Model
|--------------------------------------------------------------------------
|
| When using the "Eloquent" authentication driver, we need to know which
| Eloquent model should be used to retrieve your users. Of course, it
| is often just the "User" model but you may use whatever you like.
|
*/

'model' => 'User',

/*
|--------------------------------------------------------------------------
| Authentication Table
|--------------------------------------------------------------------------
|
| When using the "Database" authentication driver, we need to know which
| table should be used to retrieve your users. We have chosen a basic
| default value but you may easily change it to any table you like.
|
*/

'table' => 'users',

/*
|--------------------------------------------------------------------------
| Password Reminder Settings
|--------------------------------------------------------------------------
|
| Here you may set the settings for password reminders, including a view
| that should be used as your password reminder e-mail. You will also
| be able to set the name of the table that holds the reset tokens.
|
| The "expire" time is the number of minutes that the reminder should be
| considered valid. This security feature keeps tokens short-lived so
| they have less time to be guessed. You may change this as needed.
|
*/

'reminder' => array(

    'email' => 'emails.auth.reminder',

    'table' => 'password_reminders',

    'expire' => 60,

),

);

此外,我尝试在_boostrap.php中添加以下功能测试,但仍无法通过谷歌驱动程序,我认为这里有问题。

Auth::LoginUsingId(1);

0 个答案:

没有答案