Skip to content
Snippets Groups Projects
  1. May 31, 2016
    • Christian Kuhn's avatar
      [BUGFIX] Get current locale without changing environment · 84e1fc32
      Christian Kuhn authored
      Two tests in ext:form change the environment when they try to
      back up the current locale:
      setlocale(LC_NUMERIC, null): "the locale names will be set from
      the values of environment variables", should be
      setlocale(LC_NUMERIC, 0): "the locale setting is not affected,
      only the current setting is returned"
      In my case my default LC_NUMERIC is "C" and after call with 'null'
      it is set to and returns 'de_DE.utf8', so it changes the internal
      state to something else than before and the reset from backup does
      not work properly. This leads to hard to debug problems if other
      locale depending tests are executed later.
      As a fun fact, phpunit suffers from the same issue and its
      api method "setlocale()" that should take care of proper reset
      messes this up, too. A pull request is pending to fix that.
      
      The patch fixes the affected unit tests and cleans them up
      along the way. Another patch to improve the overall situation
      regarding locale handling in unit tests will follow later.
      
      Change-Id: I2295b46cc6934a48e4d71ef5170deb83fb9264b6
      Resolves: #76389
      Releases: master
      Reviewed-on: https://review.typo3.org/48416
      
      
      Reviewed-by: default avatarMarkus Klein <markus.klein@typo3.org>
      Tested-by: default avatarMarkus Klein <markus.klein@typo3.org>
      Reviewed-by: default avatarMorton Jonuschat <m.jonuschat@mojocode.de>
      Tested-by: default avatarMorton Jonuschat <m.jonuschat@mojocode.de>
      84e1fc32
  2. May 30, 2016
  3. May 29, 2016
  4. May 28, 2016
  5. May 27, 2016