public function FeedsTamperWebTestHelper::setUp in Feeds Tamper 7
Same name and namespace in other branches
- 6 tests/feeds_tamper.test \FeedsTamperWebTestHelper::setUp()
3 calls to FeedsTamperWebTestHelper::setUp()
- FeedsTamperEfqFinderTestCase::setUp in tests/
feeds_tamper_efq_finder.test - FeedsTamperUIWebTestCase::setUp in feeds_tamper_ui/
tests/ feeds_tamper_ui.test - FeedsTamperWebTestCase::setUp in tests/
feeds_tamper.test
3 methods override FeedsTamperWebTestHelper::setUp()
- FeedsTamperEfqFinderTestCase::setUp in tests/
feeds_tamper_efq_finder.test - FeedsTamperUIWebTestCase::setUp in feeds_tamper_ui/
tests/ feeds_tamper_ui.test - FeedsTamperWebTestCase::setUp in tests/
feeds_tamper.test
File
- tests/
feeds_tamper.test, line 13 - Tests for feeds_tamper.module.
Class
- FeedsTamperWebTestHelper
- Base class for Feeds Tamper tests.
Code
public function setUp() {
$args = func_get_args();
// Build the list of required modules which can be altered by passing in an
// array of module names to setUp().
if (isset($args[0])) {
if (is_array($args[0])) {
$modules = $args[0];
}
else {
$modules = $args;
}
}
else {
$modules = array();
}
if (isset($args[1]) && is_array($args[1])) {
$permissions = $args[1];
}
else {
$permissions = array();
}
$modules[] = 'feeds_tamper';
parent::setUp($modules, $permissions);
// Detect if Feeds menu structure has changed. This will take a while to be
// released, but since I run dev it needs to work.
$feeds_menu = feeds_ui_menu();
if (isset($feeds_menu['admin/structure/feeds/list'])) {
$this->feeds_base = 'admin/structure/feeds/edit';
}
else {
$this->feeds_base = 'admin/structure/feeds';
}
}