test: add expect exception message

This commit is contained in:
vnmedeiros 2022-08-03 16:21:58 -03:00
parent 46e12d61ec
commit 6bc612c565
1 changed files with 1 additions and 0 deletions

View File

@ -128,6 +128,7 @@ class MetadataSection extends TAINACAN_UnitTestCase {
$this->assertTrue(empty($section_empty)); $this->assertTrue(empty($section_empty));
$this->setExpectedException(\Exception::class); $this->setExpectedException(\Exception::class);
$this->expectExceptionMessage('The metadata section must not contain metadata before deleted');
$section = $Tainacan_Metadata_Section->fetch($metadata_section_no_delete->get_id()); $section = $Tainacan_Metadata_Section->fetch($metadata_section_no_delete->get_id());
$Tainacan_Metadata_Section->delete($section); $Tainacan_Metadata_Section->delete($section);