Uploaded image for project: 'Spring.NET'
  1. Spring.NET
  2. SPRNET-1526

XmlApplicationContext throws ArgumentException when configurationLocations not specified, but configurationResources specified

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 1.3.2, 2.0 M1
    • Fix Version/s: None
    • Component/s: Spring-NET-CORE
    • Labels:
      None

      Description

      Spring.Context.Support.XmlApplicationContext(bool refresh, string name, bool caseSensitive, IApplicationContext parentContext, string[] configurationLocations, IResource[] configurationResources) 

      throws ArgumentException : "You must provide either or both Configuration Locations and/or Configuration Resources!", when configurationLocations not specified, but configurationResources specified. In souce code i found that constructor call contains typo: it passes null instead of configurationResources.
      I think it shoul be

      XmlApplicationContext.cs
              public XmlApplicationContext(
               bool refresh,
               string name,
               bool caseSensitive,
               IApplicationContext parentContext,
               string[] configurationLocations,
               IResource[] configurationResources)
                  : this(new XmlApplicationContextArgs(name, parentContext, configurationLocations, configurationResources, caseSensitive, refresh))
              { }
      

        Attachments

          Activity

            People

            Assignee:
            sbohlen Steve Bohlen
            Reporter:
            asbestos Alexander V. Titov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: