session()->inst_set('loggedInAs', $this->idFromFixture('Member', 'admin'));
/* First, open the applicable group */
$this->get('admin/security/getitem?ID=' . $this->idFromFixture('Group','admin'));
$this->assertRegExp('/]+id="Form_EditForm_Title"[^>]+value="Administrators"[^>]*>/',$this->content());
/* Then load the export page */
$this->get('admin/security//EditForm/field/Members/export');
$this->assertRegExp('/"FirstName","Surname","Email"/', $this->content());
$this->assertRegExp('/"","","admin@example.com"/', $this->content());
}
function testEmptyGroupExport() {
$this->session()->inst_set('loggedInAs', $this->idFromFixture('Member', 'admin'));
/* First, open the applicable group */
$this->get('admin/security/getitem?ID=' . $this->idFromFixture('Group','empty'));
$this->assertRegExp('/]+id="Form_EditForm_Title"[^>]+value="Empty Group"[^>]*>/',$this->content());
/* Then load the export page */
$this->get('admin/security//EditForm/field/Members/export');
$this->assertRegExp('/"FirstName","Surname","Email"/', $this->content());
}
}
?>