Announcement Announcement Module
Collapse
No announcement yet.
Odd Javadoc for AbstractDependencyInjectionSpringContextTests Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Odd Javadoc for AbstractDependencyInjectionSpringContextTests

    Hello,

    I've just noticed that Javadoc for private injectDependencies() method in AbstractDependencyInjectionSpringContextTests says:

    "Inject dependencies into 'this' instance (that is, this test instance).
    The default implementation populates protected variables if the appropriate flag is set, else uses autowiring if autowiring is switched on (which it is by default).
    You can certainly override this method if you want to totally control how dependencies are injected into 'this' instance."

    Isn't it strange that it's advised to override private method?

  • #2
    Sorry, I forgot to mention that I'm using Spring 2.0.2.

    Comment


    • #3
      Have you tried looking at the history of the file? Did it used to be lower scope?

      Comment


      • #4
        No I haven't, but I think that Javadoc comment was supposed to be for protected method prepareTestInstance() in the same class. It makes sense to override that one.

        Comment


        • #5
          I think you should create a JIRA issue, so the spring team know about this minor bug.

          Comment


          • #6
            Originally posted by davsclaus View Post
            I think you should create a JIRA issue, so the spring team know about this minor bug.
            Yeah makes sense, if they don't know they can't fix it!

            Comment


            • #7
              It looks like someone else has already found that issue and it's fixed for Spring 2.0.3.

              Comment


              • #8
                Ahhh the system works .

                Comment

                Working...
                X