Merge pull request #49 from ericklombardo/master

Resolved issue SPRNET-1547
This commit is contained in:
Marko Lahma
2013-11-10 02:45:58 -08:00
3 changed files with 24 additions and 1 deletions

View File

@@ -119,6 +119,15 @@ namespace Spring.Context.Config
Assert.That(prototypeDef.IsLazyInit, Is.True);
}
[Test]
public void ComponentsUseDefaultAutoWire()
{
_applicationContext = new XmlApplicationContext(ReadOnlyXmlTestResource.GetFilePath("ConfigFiles.ComponentScan5.xml", GetType()));
var prototypeDef = _applicationContext.ObjectFactory.GetObjectDefinition("Prototype");
Assert.That(prototypeDef.AutowireMode == AutoWiringMode.ByName);
}
[Test]
public void ComponentWithQualifier()
{

View File

@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<objects xmlns="http://www.springframework.net"
xmlns:context="http://www.springframework.net/context"
default-lazy-init="true">
default-lazy-init="true" default-autowire="byName">
<context:component-scan base-assemblies="Spring.Core.Tests">
<context:include-filter type="regex" expression="ComponentScan.ComponentsUseDefaults.*"/>