Skip to content

Configuration validation. verify() ? #15

Description

@fljot

@darscan @creynders and everyone still alive,

what do you think about some verification API?
http://stackoverflow.com/questions/9896344/ioc-container-check-for-errors-at-compile-time

Case: I want to ensure my configuration is correct (no missing unmapped injections), in other words that all my dependencies tree can be successfully resolved. In my test I would get my configured injector (e.g. get actual configured context) and call verify() (for instance) on them.
I would expect injector (and it's parent injectors) to run through all mappings (Injector#_mappings) and call corresponding getInstance().

What do you think? I would be glad to implement it and make PR if I know it would be accepted.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions