You are here

function ContactSitewideTestCase::addCategory in Contact 7.2

Same name and namespace in other branches
  1. 6.2 contact.test \ContactSitewideTestCase::addCategory()

Add a category.

Parameters

string $category Name of category.:

string $recipients List of recipient e-mail addresses.:

string $reply Auto-reply text.:

boolean $selected Defautly selected.:

2 calls to ContactSitewideTestCase::addCategory()
ContactSitewideTestCase::testAutoReply in ./contact.test
Test auto-reply on the site-wide contact form.
ContactSitewideTestCase::testSiteWideContact in ./contact.test
Test configuration options and site-wide contact form.

File

./contact.test, line 210
Tests for contact.module.

Class

ContactSitewideTestCase
@file Tests for contact.module.

Code

function addCategory($category, $recipients, $reply, $selected) {
  $edit = array();
  $edit['category'] = $category;
  $edit['recipients'] = $recipients;
  $edit['reply'] = $reply;
  $edit['selected'] = $selected ? '1' : '0';
  $this
    ->drupalPost('admin/structure/contact/add', $edit, t('Save'));
}