Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F93011450
ConduitCallTestCase.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Mon, Nov 25, 13:58
Size
622 B
Mime Type
text/x-php
Expires
Wed, Nov 27, 13:58 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
22557269
Attached To
rPH Phabricator
ConduitCallTestCase.php
View Options
<?php
final
class
ConduitCallTestCase
extends
PhabricatorTestCase
{
public
function
testConduitPing
()
{
$call
=
new
ConduitCall
(
'conduit.ping'
,
array
());
$result
=
$call
->
execute
();
$this
->
assertFalse
(
empty
(
$result
));
}
public
function
testConduitAuth
()
{
$call
=
new
ConduitCall
(
'user.whoami'
,
array
(),
true
);
$caught
=
null
;
try
{
$result
=
$call
->
execute
();
}
catch
(
ConduitException
$ex
)
{
$caught
=
$ex
;
}
$this
->
assertTrue
(
(
$caught
instanceof
ConduitException
),
pht
(
'%s should require authentication.'
,
'user.whoami'
));
}
}
Event Timeline
Log In to Comment