Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F4793035
ServiceTest.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
ServiceTest.php
View Options
<?php
namespace
Nasqueron\Notifications\Tests\Config\Services
;
use
Nasqueron\Notifications\Config\Services\Service
;
use
Nasqueron\Notifications\Tests\TestCase
;
class
ServiceTest
extends
TestCase
{
/**
* @var \Nasqueron\Notifications\Config\Services\Service
*/
private
$serviceWithInstance
;
/**
* @var \Nasqueron\Notifications\Config\Services\Service
*/
private
$serviceWithoutInstance
;
public
function
setUp
()
{
$this
->
serviceWithoutInstance
=
new
Service
();
$this
->
serviceWithInstance
=
clone
$this
->
serviceWithoutInstance
;
$this
->
serviceWithInstance
->
instance
=
"http://www.perdu.com"
;
}
///
/// Tests for getInstanceName()
///
public
function
testGetInstanceName
()
{
$this
->
assertSame
(
"http://www.perdu.com"
,
$this
->
serviceWithInstance
->
getInstanceName
()
);
}
public
function
testGetInstanceNameWhenThereIsNoInstance
()
{
$this
->
assertSame
(
"ø"
,
$this
->
serviceWithoutInstance
->
getInstanceName
()
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Fri, Feb 28, 21:39 (1 d, 5 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2439184
Default Alt Text
ServiceTest.php (1 KB)
Attached To
Mode
rNOTIF Notifications center
Attached
Detach File
Event Timeline
Log In to Comment