~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_merge.py

  • Committer: Robert Collins
  • Date: 2010-01-28 18:05:44 UTC
  • mto: (4797.2.5 2.1)
  • mto: This revision was merged to the branch mainline in revision 4989.
  • Revision ID: robertc@robertcollins.net-20100128180544-6l8x7o7obaq7b51x
Tweak ConfigurableFileMerger to use class variables rather than requiring __init__ wrapping as future proofing for helper functions.

Show diffs side-by-side

added added

removed removed

Lines of Context:
2844
2844
    def test_affected_files_cached(self):
2845
2845
        """Ensures that the config variable is cached"""
2846
2846
        class SimplePlan(_mod_merge.ConfigurableFileMerger):
 
2847
            name_prefix = "foo"
 
2848
            default_files = ["my default"]
2847
2849
            def merge_text(self, params):
2848
2850
                return ('not applicable', None)
2849
2851
        def factory(merger):
2850
 
            result = SimplePlan(merger, "foo", ["my default"])
 
2852
            result = SimplePlan(merger)
2851
2853
            self.assertEqual(None, result.affected_files)
2852
2854
            self.merger = result
2853
2855
            return result