summaryrefslogtreecommitdiff
path: root/modules/book
diff options
context:
space:
mode:
authorDavid Rothstein <drothstein@gmail.com>2012-06-04 01:07:43 -0400
committerDavid Rothstein <drothstein@gmail.com>2012-06-04 01:07:43 -0400
commitbbe4b34681f9bb52c344ac4475c1adc7b5c3f601 (patch)
treebf05ebf2c6df41b141eaf9f3f04737d894449a4c /modules/book
parent31a4cbdb0e804a66ef3f602450c872cefa949cbb (diff)
downloadbrdo-bbe4b34681f9bb52c344ac4475c1adc7b5c3f601.tar.gz
brdo-bbe4b34681f9bb52c344ac4475c1adc7b5c3f601.tar.bz2
Issue #1600892 by tim.plunkett, sun: Fixed Tests use magic numbers 1 and 2 instead of user role constants.
Diffstat (limited to 'modules/book')
-rw-r--r--modules/book/book.test8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/book/book.test b/modules/book/book.test
index 6c351b8ec..1ec1fe92f 100644
--- a/modules/book/book.test
+++ b/modules/book/book.test
@@ -279,8 +279,8 @@ class BookTestCase extends DrupalWebTestCase {
// Give anonymous users the permission 'node test view'.
$edit = array();
- $edit['1[node test view]'] = TRUE;
- $this->drupalPost('admin/people/permissions/1', $edit, t('Save permissions'));
+ $edit[DRUPAL_ANONYMOUS_RID . '[node test view]'] = TRUE;
+ $this->drupalPost('admin/people/permissions/' . DRUPAL_ANONYMOUS_RID, $edit, t('Save permissions'));
$this->assertText(t('The changes have been saved.'), t("Permission 'node test view' successfully assigned to anonymous users."));
// Test correct display of the block.
@@ -315,8 +315,8 @@ class BookTestCase extends DrupalWebTestCase {
// Give anonymous users the permission 'node test view'.
$edit = array();
- $edit['1[node test view]'] = TRUE;
- $this->drupalPost('admin/people/permissions/1', $edit, t('Save permissions'));
+ $edit[DRUPAL_ANONYMOUS_RID . '[node test view]'] = TRUE;
+ $this->drupalPost('admin/people/permissions/' . DRUPAL_ANONYMOUS_RID, $edit, t('Save permissions'));
$this->assertText(t('The changes have been saved.'), t('Permission \'node test view\' successfully assigned to anonymous users.'));
// Create a book.