You are here

function BackupMigrateUnitTest::removeDrupalMessage in Backup and Migrate 5

1 call to BackupMigrateUnitTest::removeDrupalMessage()
BackupMigrateUnitTest::testCreateBackupDirectory in tests/BackupMigrateUnitTest.test

File

tests/BackupMigrateUnitTest.test, line 729

Class

BackupMigrateUnitTest
Unit tests for Backup and Migrate module.

Code

function removeDrupalMessage($type, $drupal_message) {
  foreach (@$_SESSION['messages'][$type] as $key => $session_message) {
    if ($session_message == $drupal_message) {
      unset($_SESSION['messages'][$type][$key]);
    }
  }
}