function QuoteTest::addFormat in Quote 7
Add a (default) text format to contain the quote filter.
1 call to QuoteTest::addFormat()
- QuoteTest::setUp in tests/
quote.test - Sets up a Drupal site for running functional and integration tests.
File
- tests/
quote.test, line 64 - Test the Quote filter.
Class
- QuoteTest
- @file Test the Quote filter.
Code
function addFormat() {
$format = new stdClass();
$format->format = 'quote_format';
$format->name = 'Quote format';
$format->weight = -100;
filter_format_save($format);
// Add standard filters.
$format->filters['autop']['status'] = 1;
$format->filters['html']['status'] = 1;
$format->filters['url']['status'] = 1;
// Add quote filter and save.
$format->filters['quote']['status'] = 1;
filter_format_save($format);
// Clear cache.
$this
->checkPermissions(array(), TRUE);
$this->quoteFormat = $format;
}