@@ 109-119 (lines=11) @@ | ||
106 | $this->assertTrue($category->canEdit($editor), 'Editor should be able to edit category.'); |
|
107 | } |
|
108 | ||
109 | public function testCanCreate() |
|
110 | { |
|
111 | $this->useDraftSite(); |
|
112 | ||
113 | $admin = $this->objFromFixture('Member', 'Admin'); |
|
114 | $editor = $this->objFromFixture('Member', 'Editor'); |
|
115 | ||
116 | $category = singleton('BlogCategory'); |
|
117 | ||
118 | $this->assertTrue($category->canCreate($admin), 'Admin should be able to create category.'); |
|
119 | $this->assertTrue($category->canCreate($editor), 'Editor should be able to create category.'); |
|
120 | } |
|
121 | ||
122 | public function testCanDelete() |
@@ 115-125 (lines=11) @@ | ||
112 | $this->assertTrue($tag->canEdit($editor), 'Editor should be able to edit tag.'); |
|
113 | } |
|
114 | ||
115 | public function testCanCreate() |
|
116 | { |
|
117 | $this->useDraftSite(); |
|
118 | ||
119 | $admin = $this->objFromFixture('Member', 'Admin'); |
|
120 | $editor = $this->objFromFixture('Member', 'Editor'); |
|
121 | ||
122 | $tag = singleton('BlogTag'); |
|
123 | ||
124 | $this->assertTrue($tag->canCreate($admin), 'Admin should be able to create tag.'); |
|
125 | $this->assertTrue($tag->canCreate($editor), 'Editor should be able to create tag.'); |
|
126 | } |
|
127 | ||
128 | public function testCanDelete() |