Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
drupal-3253715
Manage
Activity
Members
Labels
Plan
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Issue forks
drupal-3253715
Commits
d2e87e2a
Commit
d2e87e2a
authored
11 years ago
by
Jennifer Hodgdon
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#1797242
by xjm, dcam, Lars Toomre, izus: Remove t() from assert messages in xmlrpc module
parent
38dd08b1
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/simpletest/tests/xmlrpc.test
+8
-8
8 additions, 8 deletions
modules/simpletest/tests/xmlrpc.test
with
8 additions
and
8 deletions
modules/simpletest/tests/xmlrpc.test
+
8
−
8
View file @
d2e87e2a
...
...
@@ -48,7 +48,7 @@ class XMLRPCBasicTestCase extends DrupalWebTestCase {
$url
=
url
(
NULL
,
array
(
'absolute'
=>
TRUE
))
.
'xmlrpc.php'
;
$signature
=
xmlrpc
(
$url
,
array
(
'system.methodSignature'
=>
array
(
'system.listMethods'
)));
$this
->
assert
(
is_array
(
$signature
)
&&
!
empty
(
$signature
)
&&
is_array
(
$signature
[
0
]),
t
(
'system.methodSignature returns an array of signature arrays.'
)
)
;
'system.methodSignature returns an array of signature arrays.'
);
}
/**
...
...
@@ -58,19 +58,19 @@ class XMLRPCBasicTestCase extends DrupalWebTestCase {
$invalid_messages
=
array
(
array
(
'message'
=>
xmlrpc_message
(
''
),
'assertion'
=>
t
(
'Empty message correctly rejected during parsing.'
)
,
'assertion'
=>
'Empty message correctly rejected during parsing.'
,
),
array
(
'message'
=>
xmlrpc_message
(
'<?xml version="1.0" encoding="ISO-8859-1"?>'
),
'assertion'
=>
t
(
'Empty message with XML declaration correctly rejected during parsing.'
)
,
'assertion'
=>
'Empty message with XML declaration correctly rejected during parsing.'
,
),
array
(
'message'
=>
xmlrpc_message
(
'<?xml version="1.0"?><params><param><value><string>value</string></value></param></params>'
),
'assertion'
=>
t
(
'Non-empty message without a valid message type is rejected during parsing.'
)
,
'assertion'
=>
'Non-empty message without a valid message type is rejected during parsing.'
,
),
array
(
'message'
=>
xmlrpc_message
(
'<methodResponse><params><param><value><string>value</string></value></param></methodResponse>'
),
'assertion'
=>
t
(
'Non-empty malformed message is rejected during parsing.'
)
,
'assertion'
=>
'Non-empty malformed message is rejected during parsing.'
,
),
);
...
...
@@ -217,7 +217,7 @@ class XMLRPCMessagesTestCase extends DrupalWebTestCase {
$xml_message_l
=
xmlrpc_test_message_sized_in_kb
(
$size
);
$xml_message_r
=
xmlrpc
(
$xml_url
,
array
(
'messages.messageSizedInKB'
=>
array
(
$size
)));
$this
->
assertEqual
(
$xml_message_l
,
$xml_message_r
,
t
(
'XML-RPC messages.messageSizedInKB of %s Kb size received'
,
array
(
'%s'
=>
$size
)));
$this
->
assertEqual
(
$xml_message_l
,
$xml_message_r
,
format_string
(
'XML-RPC messages.messageSizedInKB of %s Kb size received'
,
array
(
'%s'
=>
$size
)));
}
}
...
...
@@ -236,9 +236,9 @@ class XMLRPCMessagesTestCase extends DrupalWebTestCase {
$methods2
=
xmlrpc
(
$url
,
array
(
'system.listMethods'
=>
array
()));
$diff
=
array_diff
(
$methods1
,
$methods2
);
$this
->
assertTrue
(
is_array
(
$diff
)
&&
!
empty
(
$diff
),
t
(
'Method list is altered by hook_xmlrpc_alter'
)
)
;
$this
->
assertTrue
(
is_array
(
$diff
)
&&
!
empty
(
$diff
),
'Method list is altered by hook_xmlrpc_alter'
);
$removed
=
reset
(
$diff
);
$this
->
assertEqual
(
$removed
,
'system.methodSignature'
,
t
(
'Hiding builting system.methodSignature with hook_xmlrpc_alter works'
)
)
;
$this
->
assertEqual
(
$removed
,
'system.methodSignature'
,
'Hiding builting system.methodSignature with hook_xmlrpc_alter works'
);
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment