Commit 30c2afed authored by webchick's avatar webchick
Browse files

Issue #697760 by sun: Replace getInfo() in tests with native phpDoc +...

Issue #697760 by sun: Replace getInfo() in tests with native phpDoc + annotations (following PHPUnit).
parent f905406d
......@@ -10,8 +10,9 @@
use Drupal\simpletest\WebTestBase;
/**
* Tests action uninstallation.
* Tests that uninstalling actions does not remove other module's actions.
*
* @group action
* @see \Drupal\action\Plugin\views\field\BulkForm
*/
class ActionUninstallTest extends WebTestBase {
......@@ -23,14 +24,6 @@ class ActionUninstallTest extends WebTestBase {
*/
public static $modules = array('views', 'action');
public static function getInfo() {
return array(
'name' => 'Uninstall action test',
'description' => 'Tests that uninstalling actions does not remove other module\'s actions.',
'group' => 'Action',
);
}
/**
* Tests Action uninstall.
*/
......
......@@ -13,6 +13,7 @@
/**
* Tests the views bulk form test.
*
* @group action
* @see \Drupal\action\Plugin\views\field\BulkForm
*/
class BulkFormTest extends WebTestBase {
......@@ -24,14 +25,6 @@ class BulkFormTest extends WebTestBase {
*/
public static $modules = array('node', 'action_bulk_test');
public static function getInfo() {
return array(
'name' => 'Bulk form',
'description' => 'Tests the views bulk form test.',
'group' => 'Action',
);
}
/**
* Tests the bulk form.
*/
......
......@@ -11,7 +11,10 @@
use Drupal\simpletest\WebTestBase;
/**
* Actions configuration.
* Tests complex actions configuration by adding, editing, and deleting a
* complex action.
*
* @group action
*/
class ConfigurationTest extends WebTestBase {
......@@ -22,14 +25,6 @@ class ConfigurationTest extends WebTestBase {
*/
public static $modules = array('action');
public static function getInfo() {
return array(
'name' => 'Actions configuration',
'description' => 'Tests complex actions configuration by adding, editing, and deleting a complex action.',
'group' => 'Action',
);
}
/**
* Tests configuration of advanced actions through administration interface.
*/
......
......@@ -10,21 +10,12 @@
use Drupal\Tests\Core\Menu\LocalTaskIntegrationTest;
/**
* Tests existence of action local tasks.
* Tests action local tasks.
*
* @group Drupal
* @group Action
* @group action
*/
class ActionLocalTasksTest extends LocalTaskIntegrationTest {
public static function getInfo() {
return array(
'name' => 'Action local tasks test',
'description' => 'Test action local tasks.',
'group' => 'Action',
);
}
public function setUp() {
$this->directoryList = array('action' => 'core/modules/action');
parent::setUp();
......
......@@ -8,17 +8,11 @@
namespace Drupal\aggregator\Tests;
/**
* Tests adding aggregator feeds.
* Add feed test.
*
* @group aggregator
*/
class AddFeedTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Add feed functionality',
'description' => 'Add feed test.',
'group' => 'Aggregator'
);
}
/**
* Creates and ensures that a feed is unique, checks source, and deletes feed.
*/
......
......@@ -8,17 +8,11 @@
namespace Drupal\aggregator\Tests;
/**
* Tests functionality of the configuration settings in the Aggregator module.
* Tests aggregator settings page.
*
* @group aggregator
*/
class AggregatorConfigurationTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Aggregator configuration',
'description' => 'Test aggregator settings page.',
'group' => 'Aggregator',
);
}
/**
* Tests the settings form to ensure the correct default values are used.
*/
......
......@@ -8,17 +8,11 @@
namespace Drupal\aggregator\Tests;
/**
* Tests functionality of the cron process in the Aggregator module.
* Update feeds on cron.
*
* @group aggregator
*/
class AggregatorCronTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Update on cron functionality',
'description' => 'Update feeds on cron.',
'group' => 'Aggregator'
);
}
/**
* Adds feeds and updates them via cron process.
*/
......
......@@ -10,7 +10,9 @@
use Drupal\Component\Utility\String;
/**
* Tests rendering functionality in the Aggregator module.
* Tests display of aggregator items on the page.
*
* @group aggregator
*/
class AggregatorRenderingTest extends AggregatorTestBase {
......@@ -21,14 +23,6 @@ class AggregatorRenderingTest extends AggregatorTestBase {
*/
public static $modules = array('block', 'test_page_test');
public static function getInfo() {
return array(
'name' => 'Checks display of aggregator items',
'description' => 'Checks display of aggregator items on the page.',
'group' => 'Aggregator'
);
}
/**
* Adds a feed block to the page and checks its links.
*/
......
......@@ -8,17 +8,11 @@
namespace Drupal\aggregator\Tests;
/**
* Tests functionality of removing a feed item in the Aggregator module.
* Delete feed items from a feed.
*
* @group aggregator
*/
class DeleteFeedItemTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Delete feed item functionality',
'description' => 'Delete feed items from a feed.',
'group' => 'Aggregator'
);
}
/**
* Tests running "delete items" from 'admin/config/services/aggregator' page.
*/
......
......@@ -8,7 +8,9 @@
namespace Drupal\aggregator\Tests;
/**
* Tests functionality for removing feeds in the Aggregator module.
* Delete feed test.
*
* @group aggregator
*/
class DeleteFeedTest extends AggregatorTestBase {
......@@ -19,14 +21,6 @@ class DeleteFeedTest extends AggregatorTestBase {
*/
public static $modules = array('block');
public static function getInfo() {
return array(
'name' => 'Delete feed functionality',
'description' => 'Delete feed test.',
'group' => 'Aggregator'
);
}
/**
* Deletes a feed and ensures that all of its services are deleted.
*/
......
......@@ -8,20 +8,13 @@
namespace Drupal\aggregator\Tests;
/**
* Tests feed fetching in the Aggregator module.
* Tests the fetcher plugins functionality and discoverability.
*
* @group aggregator
* @see \Drupal\aggregator_test\Plugin\aggregator\fetcher\TestFetcher.
*/
class FeedFetcherPluginTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Feed fetcher plugins',
'description' => 'Test the fetcher plugins functionality and discoverability.',
'group' => 'Aggregator',
);
}
public function setUp() {
parent::setUp();
// Enable test plugins.
......
......@@ -11,6 +11,8 @@
/**
* Tests aggregator feeds in multiple languages.
*
* @group aggregator
*/
class FeedLanguageTest extends AggregatorTestBase {
......@@ -28,14 +30,6 @@ class FeedLanguageTest extends AggregatorTestBase {
*/
protected $langcodes = array();
public static function getInfo() {
return array(
'name' => 'Multilingual feeds',
'description' => 'Checks creating of feeds in multiple languages',
'group' => 'Aggregator',
);
}
public function setUp() {
parent::setUp();
......
......@@ -10,17 +10,11 @@
use Zend\Feed\Reader\Reader;
/**
* Tests feed parsing in the Aggregator module.
* Tests the built-in feed parser with valid feed samples.
*
* @group aggregator
*/
class FeedParserTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Feed parser functionality',
'description' => 'Test the built-in feed parser with valid feed samples.',
'group' => 'Aggregator',
);
}
function setUp() {
parent::setUp();
// Do not delete old aggregator items during these tests, since our sample
......
......@@ -8,20 +8,13 @@
namespace Drupal\aggregator\Tests;
/**
* Tests feed processing in the Aggregator module.
* Tests the processor plugins functionality and discoverability.
*
* @group aggregator
* @see \Drupal\aggregator_test\Plugin\aggregator\processor\TestProcessor.
*/
class FeedProcessorPluginTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Feed processor plugins',
'description' => 'Test the processor plugins functionality and discoverability.',
'group' => 'Aggregator',
);
}
/**
* Overrides \Drupal\simpletest\WebTestBase::setUp().
*/
......
......@@ -8,7 +8,9 @@
namespace Drupal\aggregator\Tests;
/**
* Tests importing feeds from OPML functionality for the Aggregator module.
* Tests OPML import.
*
* @group aggregator
*/
class ImportOpmlTest extends AggregatorTestBase {
......@@ -19,14 +21,6 @@ class ImportOpmlTest extends AggregatorTestBase {
*/
public static $modules = array('block');
public static function getInfo() {
return array(
'name' => 'Import feeds from OPML functionality',
'description' => 'Test OPML import.',
'group' => 'Aggregator',
);
}
function setUp() {
parent::setUp();
......
......@@ -9,17 +9,11 @@
use Drupal\aggregator\Entity\Feed;
/**
* Tests functionality of updating a feed item in the Aggregator module.
* Update feed items from a feed.
*
* @group aggregator
*/
class UpdateFeedItemTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Update feed item functionality',
'description' => 'Update feed items from a feed.',
'group' => 'Aggregator'
);
}
/**
* Tests running "update items" from 'admin/config/services/aggregator' page.
*/
......
......@@ -8,17 +8,11 @@
namespace Drupal\aggregator\Tests;
/**
* Tests functionality of updating the feed in the Aggregator module.
* Update feed test.
*
* @group aggregator
*/
class UpdateFeedTest extends AggregatorTestBase {
public static function getInfo() {
return array(
'name' => 'Update feed functionality',
'description' => 'Update feed test.',
'group' => 'Aggregator'
);
}
/**
* Creates a feed and attempts to update it.
*/
......
......@@ -12,7 +12,9 @@
use Drupal\views\Tests\ViewUnitTestBase;
/**
* Tests basic views integration of aggregator module.
* Tests basic integration of views data from the aggregator module.
*
* @group aggregator
*/
class IntegrationTest extends ViewUnitTestBase {
......@@ -44,14 +46,6 @@ class IntegrationTest extends ViewUnitTestBase {
*/
protected $feedStorage;
public static function getInfo() {
return array(
'name' => 'Aggregator: Integration tests',
'description' => 'Tests basic integration of views data from the aggregator module.',
'group' => 'Views module integration',
);
}
protected function setUp() {
parent::setUp();
......
......@@ -12,19 +12,10 @@
/**
* Tests existence of aggregator local tasks.
*
* @group Drupal
* @group Aggregator
* @group aggregator
*/
class AggregatorLocalTasksTest extends LocalTaskIntegrationTest {
public static function getInfo() {
return array(
'name' => 'Aggregator local tasks test',
'description' => 'Test existence of aggregator local tasks.',
'group' => 'Aggregator',
);
}
public function setUp() {
$this->directoryList = array('aggregator' => 'core/modules/aggregator');
parent::setUp();
......
......@@ -11,10 +11,9 @@
use Drupal\Tests\UnitTestCase;
/**
* Tests plugins settings on aggregator plugins.
* Tests settings configuration of individual aggregator plugins.
*
* @group Drupal
* @group Aggregator
* @group aggregator
*/
class AggregatorPluginSettingsBaseTest extends UnitTestCase {
......@@ -39,14 +38,6 @@ class AggregatorPluginSettingsBaseTest extends UnitTestCase {
*/
protected $managers;
public static function getInfo() {
return array(
'name' => 'Aggregator plugin settings tests',
'description' => 'Test settings configuration of individual aggregator plugins.',
'group' => 'Aggregator',
);
}
public function setUp() {
$this->configFactory = $this->getConfigFactoryStub(
array(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment