~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_ignores.py

  • Committer: Patch Queue Manager
  • Date: 2016-02-01 19:13:13 UTC
  • mfrom: (6614.2.2 trunk)
  • Revision ID: pqm@pqm.ubuntu.com-20160201191313-wdfvmfff1djde6oq
(vila) Release 2.7.0 (Vincent Ladeuil)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2006-2011 Canonical Ltd
 
1
# Copyright (C) 2006-2012, 2016 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
175
175
    
176
176
    def assertPatternsEquals(self, patterns):
177
177
        contents = open(".bzrignore", 'rU').read().strip().split('\n')
178
 
        self.assertEquals(sorted(patterns), sorted(contents))
 
178
        self.assertEqual(sorted(patterns), sorted(contents))
179
179
 
180
180
    def test_new_file(self):
181
181
        tree = self.make_branch_and_tree(".")
222
222
        self.build_tree_contents([('.bzrignore', "myentry1\r\n")])
223
223
        tree.add([".bzrignore"])
224
224
        ignores.tree_ignores_add_patterns(tree, ["myentry2", "foo"])
225
 
        self.assertEquals(open('.bzrignore', 'rb').read(), 'myentry1\r\nmyentry2\r\nfoo\r\n')
 
225
        self.assertEqual(open('.bzrignore', 'rb').read(), 'myentry1\r\nmyentry2\r\nfoo\r\n')
226
226
        self.assertPatternsEquals(["myentry1", "myentry2", "foo"])