MetaDataDictionary.getInstance( ).addStructure( structDefn1 ); MetaDataDictionary.getInstance( ).addStructure( structDefn2 );
MetadataTestUtil.addStructureDefn( MetaDataDictionary.getInstance( ), structDefn1 ); MetadataTestUtil.addStructureDefn( MetaDataDictionary.getInstance( ), structDefn2 );
	public void test_DUPLICATE_STRUCT_NAME( )	{		StructureDefn structDefn1 = new StructureDefn( "struct" ); //$NON-NLS-1$ 		StructureDefn structDefn2 = new StructureDefn( "struct" ); //$NON-NLS-1$ 		try		{			MetaDataDictionary.getInstance( ).addStructure( structDefn1 );			MetaDataDictionary.getInstance( ).addStructure( structDefn2 );			fail( );		}		catch ( MetaDataException e )		{			assertEquals(					MetaDataException.DESIGN_EXCEPTION_DUPLICATE_STRUCT_NAME, e							.getErrorCode( ) );			assertEquals(					"Message:Duplicate structure names when adding the structure [struct] to the meta-data dictionary. Error code:DUPLICATE_STRUCT_NAME", //$NON-NLS-1$ 					e.getMessage( ).trim( ) );		}	}