/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/tests/__init__.py

  • Committer: Martin
  • Date: 2019-06-16 19:53:27 UTC
  • mto: This revision was merged to the branch mainline in revision 7349.
  • Revision ID: gzlist@googlemail.com-20190616195327-awvhgbjo9g6mkt57
Relocate the bzr log file out of $HOME

Now under $XDG_CACHE_HOME on nix and %LOCALAPPDATA% on windows.

Setting $BRZ_HOME will override the cache location, to simplify test
isolation, and $BRZ_LOG is still the final word.

Drive-by fix various docs around bzr/brz spelling.

Show diffs side-by-side

added added

removed removed

Lines of Context:
155
155
    'BZREMAIL': None,  # may still be present in the environment
156
156
    'EMAIL': 'jrandom@example.com',  # set EMAIL as brz does not guess
157
157
    'BRZ_PROGRESS_BAR': None,
158
 
    # This should trap leaks to ~/.brz.log. This occurs when tests use TestCase
159
 
    # as a base class instead of TestCaseInTempDir. Tests inheriting from
160
 
    # TestCase should not use disk resources, BRZ_LOG is one.
 
158
    # Trap leaks to $XDG_CACHE_HOME/breezy/brz.log. This occurs when tests use
 
159
    # TestCase as a base class instead of TestCaseInTempDir. Tests inheriting
 
160
    # from TestCase should not use disk resources, BRZ_LOG is one.
161
161
    'BRZ_LOG': '/you-should-use-TestCaseInTempDir-if-you-need-a-log-file',
162
162
    'BRZ_PLUGIN_PATH': '-site',
163
163
    'BRZ_DISABLE_PLUGINS': None,
2684
2684
        """
2685
2685
        root = TestCaseWithMemoryTransport.TEST_ROOT
2686
2686
        try:
2687
 
            # Make sure we get a readable and accessible home for .brz.log
 
2687
            # Make sure we get a readable and accessible home for brz.log
2688
2688
            # and/or config files, and not fallback to weird defaults (see
2689
2689
            # http://pad.lv/825027).
2690
2690
            self.assertIs(None, os.environ.get('BRZ_HOME', None))