Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Rotua Panjaitan
yii2
Commits
af8f0b1a
Commit
af8f0b1a
authored
Feb 18, 2014
by
Qiang Xue
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2478 from Ragazzo/yii2_advanced_tests_fixed
Yii2 advanced tests fixed
parents
557e3430
468f8042
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
31 additions
and
19 deletions
+31
-19
LoginForm.php
apps/advanced/common/models/LoginForm.php
+1
-1
main-local.php
apps/advanced/environments/dev/backend/config/main-local.php
+11
-9
main-local.php
.../advanced/environments/dev/frontend/config/main-local.php
+11
-9
TestCase.php
apps/advanced/frontend/tests/unit/TestCase.php
+8
-0
No files found.
apps/advanced/common/models/LoginForm.php
View file @
af8f0b1a
...
...
@@ -61,7 +61,7 @@ class LoginForm extends Model
*
* @return User|null
*/
p
rivate
function
getUser
()
p
ublic
function
getUser
()
{
if
(
$this
->
_user
===
false
)
{
$this
->
_user
=
User
::
findByUsername
(
$this
->
username
);
...
...
apps/advanced/environments/dev/backend/config/main-local.php
View file @
af8f0b1a
<?php
return
[
'preload'
=>
[
'debug'
,
],
'modules'
=>
[
'debug'
=>
'yii\debug\Module'
,
'gii'
=>
'yii\gii\Module'
,
],
];
$config
=
[];
if
(
!
YII_ENV_TEST
)
{
// configuration adjustments for 'dev' environment
$config
[
'preload'
][]
=
'debug'
;
$config
[
'modules'
][
'debug'
]
=
'yii\debug\Module'
;
$config
[
'modules'
][
'gii'
]
=
'yii\gii\Module'
;
}
return
$config
;
apps/advanced/environments/dev/frontend/config/main-local.php
View file @
af8f0b1a
<?php
return
[
'preload'
=>
[
'debug'
,
],
'modules'
=>
[
'debug'
=>
'yii\debug\Module'
,
'gii'
=>
'yii\gii\Module'
,
],
];
$config
=
[];
if
(
!
YII_ENV_TEST
)
{
// configuration adjustments for 'dev' environment
$config
[
'preload'
][]
=
'debug'
;
$config
[
'modules'
][
'debug'
]
=
'yii\debug\Module'
;
$config
[
'modules'
][
'gii'
]
=
'yii\gii\Module'
;
}
return
$config
;
apps/advanced/frontend/tests/unit/TestCase.php
0 → 100644
View file @
af8f0b1a
<?php
namespace
frontend\tests\unit
;
class
TestCase
extends
\yii\codeception\TestCase
{
public
$appConfig
=
'@frontend/tests/unit/_config.php'
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment