Implement local time zone override for tests

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Fixed
    • Priority: Unknown
    • 8.1.0
    • Affects Version/s: None
    • Component/s: Tests
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Similarly to how there is config_override to override configuration options, we should also add a time_zone_override for setting Time.zone locally for a test to avoid this code:

              before do
                # if this is actually your time zone, the following tests are useless
                Time.zone = "Stockholm"
              end
      
              after do
                Time.zone = nil
              end
      

            Assignee:
            Neil Shweky (Inactive)
            Reporter:
            Oleg Pudeyev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: