Uploaded image for project: 'Magnolia'
  1. Magnolia
  2. MAGNOLIA-7804

Make system properties and environment variables injectable

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Neutral
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.2.2
    • Component/s: core
    • Labels:
      None

      Description

      Code that relies on system properties or environment variables can be hard to test (See e.g. info.magnolia.init.DefaultMagnoliaPropertiesResolver). To simplify such test setups I suggest that we introduce a component providing the values of system properties and environment variables to its users. While the default implementation just relays back to System.getenv() and System.getProperty(), test could inject their own implementations.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              mduerig Michael Duerig
              Reporter:
              mduerig Michael Duerig
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: