@Test
public void testWildcardImports() throws Exception {

	File f = TestUtils.findTestFile( "/configurations/valid/graph-with-wildcards.graph" );
	FromGraphDefinition fromDef = new FromGraphDefinition( f.getParentFile());
	Graphs graphs = fromDef.buildGraphs( f );
	Assert.assertEquals( 0, fromDef.getErrors().size());
	Collection<ModelError> errors = RuntimeModelValidator.validate( graphs );
	Assert.assertEquals( 0, errors.size());
	Component component = ComponentHelpers.findComponent( graphs, "app" );
	Assert.assertNotNull( component );
	Map<String,String> exports = ComponentHelpers.findAllExportedVariables( component );
	Assert.assertEquals( 2, exports.size());
	Assert.assertNull( exports.get( "app.ip" ));
	Assert.assertEquals( "toto", exports.get( "app.port" ));
	Map<String,ImportedVariable> imports = ComponentHelpers.findAllImportedVariables( component );
	Assert.assertEquals( 2, imports.size());
	Assert.assertNotNull( imports.get( "database.*" ));
	Assert.assertFalse( imports.get( "database.*" ).isOptional());
	Assert.assertNotNull( imports.get( "f-messaging-2.*" ));
	Assert.assertFalse( imports.get( "f-messaging-2.*" ).isOptional());
}