Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
lib
unicaen
auth
Commits
4005d2a4
Commit
4005d2a4
authored
Jul 05, 2013
by
Bertrand Gauthier
Browse files
Correction mauvaise classe.
parent
d0195c34
Changes
1
Hide whitespace changes
Inline
Side-by-side
tests/UnicaenAuthTest/Authentication/Storage/LdapTest.php
View file @
4005d2a4
...
@@ -2,7 +2,8 @@
...
@@ -2,7 +2,8 @@
namespace
UnicaenAuthTest\Authentication\Storage
;
namespace
UnicaenAuthTest\Authentication\Storage
;
use
PHPUnit_Framework_TestCase
;
use
PHPUnit_Framework_TestCase
;
use
UnicaenAppTest\Entity\Ldap\TestAsset\People
;
use
UnicaenApp\Entity\Ldap\People
;
use
UnicaenAppTest\Entity\Ldap\TestAsset\People
as
PeopleTestAsset
;
use
UnicaenAuth\Authentication\Storage\Ldap
;
use
UnicaenAuth\Authentication\Storage\Ldap
;
use
Zend\ServiceManager\ServiceManager
;
use
Zend\ServiceManager\ServiceManager
;
...
@@ -93,7 +94,7 @@ class LdapTest extends PHPUnit_Framework_TestCase
...
@@ -93,7 +94,7 @@ class LdapTest extends PHPUnit_Framework_TestCase
public
function
testReadingReturnsFoundUser
()
public
function
testReadingReturnsFoundUser
()
{
{
$entity
=
new
People
();
$entity
=
new
People
(
PeopleTestAsset
::
$data1
);
$this
->
mapper
->
expects
(
$this
->
once
())
$this
->
mapper
->
expects
(
$this
->
once
())
->
method
(
'findOneByUsername'
)
->
method
(
'findOneByUsername'
)
...
@@ -108,7 +109,7 @@ class LdapTest extends PHPUnit_Framework_TestCase
...
@@ -108,7 +109,7 @@ class LdapTest extends PHPUnit_Framework_TestCase
{
{
$this
->
mapper
->
expects
(
$this
->
once
())
$this
->
mapper
->
expects
(
$this
->
once
())
->
method
(
'findOneByUsername'
)
->
method
(
'findOneByUsername'
)
->
will
(
$this
->
returnValue
(
new
People
()));
->
will
(
$this
->
returnValue
(
new
People
(
PeopleTestAsset
::
$data1
)));
$this
->
storage
->
write
(
'username'
);
$this
->
storage
->
write
(
'username'
);
$firestResult
=
$this
->
storage
->
read
();
$firestResult
=
$this
->
storage
->
read
();
...
...
Write
Preview
Supports
Markdown
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