function UbercartCartLinksTestCase::setCartLinksUIMessages in Ubercart 6.2
Same name and namespace in other branches
- 7.3 uc_cart_links/tests/uc_cart_links.test \UbercartCartLinksTestCase::setCartLinksUIMessages()
Sets messages that can be referenced by a link.
Must be logged in with 'administer cart links' permission.
Parameters
$messages: String containing user input from a textarea, one message per line. Messages have numeric key and text value, separated by '|'.
1 call to UbercartCartLinksTestCase::setCartLinksUIMessages()
- UbercartCartLinksTestCase::testCartLinksMessages in uc_cart_links/
uc_cart_links.test - Tests cart links messages.
File
- uc_cart_links/
uc_cart_links.test, line 633 - Ubercart Cart Links Tests.
Class
- UbercartCartLinksTestCase
- SimpleTests for Ubercart Cart Links.
Code
function setCartLinksUIMessages($messages = '') {
$message_string = implode("\n", $messages);
$this
->drupalPost('admin/store/settings/cart_links', array(
'uc_cart_links_messages' => $message_string,
), t('Save configuration'));
$this
->assertFieldByName('uc_cart_links_messages', $message_string, t('Cart links messages contains "@messages".', array(
'@messages' => $message_string,
)));
}