Skip to content

Commit

Permalink
#376129 by boombatower, Damien Tournoud, and chx: Change getInfo() to…
Browse files Browse the repository at this point in the history
… a static method to reduce memory footprint of SimpleTest.
  • Loading branch information
webchick committed Mar 31, 2009
1 parent 60332ef commit 7eb0adc
Show file tree
Hide file tree
Showing 50 changed files with 262 additions and 266 deletions.
16 changes: 8 additions & 8 deletions modules/aggregator/aggregator.test
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
// $Id: aggregator.test,v 1.19 2009-03-01 07:21:02 webchick Exp $
// $Id: aggregator.test,v 1.20 2009-03-31 01:49:50 webchick Exp $

class AggregatorTestCase extends DrupalWebTestCase {
private static $prefix = 'simpletest_aggregator_';
Expand Down Expand Up @@ -243,7 +243,7 @@ EOF;
}

class AddFeedTestCase extends AggregatorTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Add feed functionality'),
'description' => t('Add feed test.'),
Expand Down Expand Up @@ -272,7 +272,7 @@ class AddFeedTestCase extends AggregatorTestCase {
}

class UpdateFeedTestCase extends AggregatorTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Update feed functionality'),
'description' => t('Update feed test.'),
Expand Down Expand Up @@ -314,7 +314,7 @@ class UpdateFeedTestCase extends AggregatorTestCase {
}

class RemoveFeedTestCase extends AggregatorTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Remove feed functionality'),
'description' => t('Remove feed test.'),
Expand Down Expand Up @@ -342,7 +342,7 @@ class RemoveFeedTestCase extends AggregatorTestCase {
}

class UpdateFeedItemTestCase extends AggregatorTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Update feed item functionality'),
'description' => t('Update feed items from a feed.'),
Expand Down Expand Up @@ -403,7 +403,7 @@ class UpdateFeedItemTestCase extends AggregatorTestCase {
}

class RemoveFeedItemTestCase extends AggregatorTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Remove feed item functionality'),
'description' => t('Remove feed items from a feed.'),
Expand Down Expand Up @@ -443,7 +443,7 @@ class RemoveFeedItemTestCase extends AggregatorTestCase {
class CategorizeFeedItemTestCase extends AggregatorTestCase {
private static $prefix = 'simpletest_aggregator_';

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Categorize feed item functionality'),
'description' => t('Test feed item categorization.'),
Expand Down Expand Up @@ -502,7 +502,7 @@ class CategorizeFeedItemTestCase extends AggregatorTestCase {
class ImportOPMLTestCase extends AggregatorTestCase {
private static $prefix = 'simpletest_aggregator_';

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Import feeds from OPML functionality'),
'description' => t('Test OPML import.'),
Expand Down
6 changes: 3 additions & 3 deletions modules/block/block.test
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php
// $Id: block.test,v 1.13 2009-03-20 19:18:09 dries Exp $
// $Id: block.test,v 1.14 2009-03-31 01:49:50 webchick Exp $

class BlockTestCase extends DrupalWebTestCase {
protected $regions;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Block functionality'),
'description' => t('Add, edit and delete custom block. Configure and move a module-defined block.'),
Expand Down Expand Up @@ -152,7 +152,7 @@ class BlockTestCase extends DrupalWebTestCase {
}

class NonDefaultBlockAdmin extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Non default theme admin'),
'description' => t('Check the administer page for non default theme.'),
Expand Down
4 changes: 2 additions & 2 deletions modules/blog/blog.test
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<?php
// $Id: blog.test,v 1.7 2009-03-20 19:18:10 dries Exp $
// $Id: blog.test,v 1.8 2009-03-31 01:49:50 webchick Exp $

class BlogTestCase extends DrupalWebTestCase {
protected $big_user;
protected $own_user;
protected $any_user;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Blog functionality'),
'description' => t('Create, view, edit, delete, and change blog entries and verify its consistency in the database.'),
Expand Down
4 changes: 2 additions & 2 deletions modules/blogapi/blogapi.test
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?php
// $Id: blogapi.test,v 1.9 2009-02-22 17:55:29 dries Exp $
// $Id: blogapi.test,v 1.10 2009-03-31 01:49:50 webchick Exp $

class BlogAPITestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Blog API functionality'),
'description' => t('Create, edit, and delete post; upload file; and set/get categories.'),
Expand Down
6 changes: 3 additions & 3 deletions modules/book/book.test
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php
// $Id: book.test,v 1.7 2008-12-23 14:32:08 dries Exp $
// $Id: book.test,v 1.8 2009-03-31 01:49:50 webchick Exp $

class BookTestCase extends DrupalWebTestCase {
protected $book;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Book functionality'),
'description' => t('Create a book, add pages, and test book interface.'),
Expand Down Expand Up @@ -174,7 +174,7 @@ class BookTestCase extends DrupalWebTestCase {
}

class BookBlockTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Block availability'),
'description' => t('Check if the book navigation block is available.'),
Expand Down
12 changes: 6 additions & 6 deletions modules/comment/comment.test
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
// $Id: comment.test,v 1.27 2009-03-25 16:54:24 dries Exp $
// $Id: comment.test,v 1.28 2009-03-31 01:49:50 webchick Exp $

class CommentHelperCase extends DrupalWebTestCase {
protected $admin_user;
Expand Down Expand Up @@ -229,7 +229,7 @@ class CommentHelperCase extends DrupalWebTestCase {
}

class CommentInterfaceTest extends CommentHelperCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Comment interface'),
'description' => t('Test comment user interfaces.'),
Expand Down Expand Up @@ -359,7 +359,7 @@ class CommentInterfaceTest extends CommentHelperCase {
}

class CommentAnonymous extends CommentHelperCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Anonymous comments'),
'description' => t('Test anonymous comments.'),
Expand Down Expand Up @@ -455,7 +455,7 @@ class CommentAnonymous extends CommentHelperCase {
}

class CommentApprovalTest extends CommentHelperCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Comment approval'),
'description' => t('Test comment approval functionality.'),
Expand Down Expand Up @@ -537,7 +537,7 @@ class CommentApprovalTest extends CommentHelperCase {
* Functional tests for the comment module blocks.
*/
class CommentBlockFunctionalTest extends CommentHelperCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Comment blocks'),
'description' => t('Test comment block functionality.'),
Expand Down Expand Up @@ -606,7 +606,7 @@ class CommentBlockFunctionalTest extends CommentHelperCase {
* Unit tests for comment module integration with RSS feeds.
*/
class CommentRSSUnitTest extends CommentHelperCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Comment RSS'),
'description' => t('Test comments as part of an RSS feed.'),
Expand Down
6 changes: 3 additions & 3 deletions modules/contact/contact.test
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php
// $Id: contact.test,v 1.15 2009-03-08 05:08:22 webchick Exp $
// $Id: contact.test,v 1.16 2009-03-31 01:49:51 webchick Exp $

/**
* Test the sitewide contact form.
*/
class ContactSitewideTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Site-wide contact form'),
'description' => t('Tests site-wide contact form functionality.'),
Expand Down Expand Up @@ -256,7 +256,7 @@ class ContactSitewideTestCase extends DrupalWebTestCase {
* Test the personal contact form.
*/
class ContactPersonalTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Personal contact form'),
'description' => t('Tests personal contact form functionality.'),
Expand Down
4 changes: 2 additions & 2 deletions modules/dblog/dblog.test
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php
// $Id: dblog.test,v 1.16 2009-03-14 23:01:36 webchick Exp $
// $Id: dblog.test,v 1.17 2009-03-31 01:49:51 webchick Exp $

class DBLogTestCase extends DrupalWebTestCase {
protected $big_user;
protected $any_user;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('DBLog functionality'),
'description' => t('Generate events and verify dblog entries; verify user access to log reports based on persmissions.'),
Expand Down
12 changes: 6 additions & 6 deletions modules/field/field.test
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php
// $Id: field.test,v 1.8 2009-03-30 05:24:38 webchick Exp $
// $Id: field.test,v 1.9 2009-03-31 01:49:51 webchick Exp $

// TODO : use drupalCreateField() / drupalCreateFieldInstance() all over ?

class FieldAttachTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Field attach tests'),
'description' => t("Test Field Attach API functions."),
Expand Down Expand Up @@ -606,7 +606,7 @@ class FieldAttachTestCase extends DrupalWebTestCase {

class FieldInfoTestCase extends DrupalWebTestCase {

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Field info tests'),
'description' => t("Get information about existing fields, instances and bundles."),
Expand Down Expand Up @@ -712,7 +712,7 @@ class FieldInfoTestCase extends DrupalWebTestCase {
}

class FieldFormTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Field form tests'),
'description' => t("Test Field form handling."),
Expand Down Expand Up @@ -919,7 +919,7 @@ class FieldFormTestCase extends DrupalWebTestCase {
}

class FieldTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Field tests'),
'description' => t("Create / read /update a field."),
Expand Down Expand Up @@ -1063,7 +1063,7 @@ class FieldTestCase extends DrupalWebTestCase {
class FieldInstanceTestCase extends DrupalWebTestCase {
protected $field;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Field instance tests'),
'description' => t("Create field entities by attaching fields to entities."),
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?php
// $Id: field_sql_storage.test,v 1.1 2009-02-03 17:30:11 dries Exp $
// $Id: field_sql_storage.test,v 1.2 2009-03-31 01:49:51 webchick Exp $

class FieldSqlStorageTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Field SQL storage tests'),
'description' => t("Test field SQL storage module."),
Expand Down
4 changes: 2 additions & 2 deletions modules/field/modules/text/text.test
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php
// $Id: text.test,v 1.2 2009-03-26 13:31:25 webchick Exp $
// $Id: text.test,v 1.3 2009-03-31 01:49:52 webchick Exp $

class TextFieldTestCase extends DrupalWebTestCase {
protected $instance;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Text Field'),
'description' => t("Test the creation of text fields."),
Expand Down
6 changes: 3 additions & 3 deletions modules/filter/filter.test
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?php
// $Id: filter.test,v 1.17 2009-03-27 00:40:42 webchick Exp $
// $Id: filter.test,v 1.18 2009-03-31 01:49:52 webchick Exp $

class FilterAdminTestCase extends DrupalWebTestCase {
function getInfo() {
public static function getInfo() {
return array(
'name' => t('Filter administration functionality'),
'description' => t('Thoroughly test the administrative interface of the filter module.'),
Expand Down Expand Up @@ -181,7 +181,7 @@ class FilterAdminTestCase extends DrupalWebTestCase {
class FilterTestCase extends DrupalWebTestCase {
protected $format;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Core filters'),
'description' => t('Filter each filter individually: Convert URLs into links, Convert line breaks, Correct broken HTML, Escape all HTML, Limit allowed HTML tags.'),
Expand Down
4 changes: 2 additions & 2 deletions modules/forum/forum.test
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
// $Id: forum.test,v 1.15 2009-02-13 05:42:24 webchick Exp $
// $Id: forum.test,v 1.16 2009-03-31 01:49:52 webchick Exp $

class ForumTestCase extends DrupalWebTestCase {
protected $big_user;
Expand All @@ -11,7 +11,7 @@ class ForumTestCase extends DrupalWebTestCase {
protected $root_forum;
protected $nids;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Forum functionality'),
'description' => t('Create, view, edit, delete, and change forum entries and verify its consistency in the database.'),
Expand Down
4 changes: 2 additions & 2 deletions modules/help/help.test
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php
// $Id: help.test,v 1.5 2009-03-08 03:39:57 webchick Exp $
// $Id: help.test,v 1.6 2009-03-31 01:49:52 webchick Exp $

class HelpTestCase extends DrupalWebTestCase {
protected $big_user;
protected $any_user;

function getInfo() {
public static function getInfo() {
return array(
'name' => t('Help functionality'),
'description' => t('Verify help display and user access to help based on persmissions.'),
Expand Down
Loading

0 comments on commit 7eb0adc

Please sign in to comment.