~abentley/bzrtools/bzrtools.dev

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
=== modified file 'shelf_tests.py'
--- shelf_tests.py	
+++ shelf_tests.py	
@@ -6,8 +6,8 @@
     ORIGINAL = '\n\nhello test world\n\n'
     MODIFIED = '\n\ngoodbye test world\n\n'
     DIFF_HEADER = "=== modified file 'test_file'\n"
-    DIFF_1 = """--- test_file
-+++ test_file
+    DIFF_1 = """--- test_file\t
++++ test_file\t
 @@ -1,4 +1,4 @@
  
  
@@ -15,8 +15,8 @@
 +goodbye test world
  
 """
-    DIFF_2 = """--- test_file
-+++ test_file
+    DIFF_2 = """--- test_file\t
++++ test_file\t
 @@ -1,4 +1,4 @@
  
  
@@ -118,14 +118,14 @@
         self.assertEqual(stderr.split('\n')[0],
             'bzr: ERROR: shelve only accepts a single revision parameter.')
 
-    def disabled_test_shelf_with_whitespace(self):
+    def test_shelf_with_whitespace(self):
         """Shows that bzr doesn't handle whitespace well"""
         self.run_bzr('init')
-        file('file\t name', 'wb').write('hello')
+        file('file name', 'wb').write('hello')
         self.run_bzr('add')
         self.run_bzr('commit', '-m', 'added')
-        file('file\t name', 'wb').write('goodbye')
-        self.run_bzr('shelve', '--all', 'file name')
+        file('file name', 'wb').write('goodbye')
+        self.run_bzr('shelve', '--all', 'file name', retcode=1)
 
     def test_whitespace_branches(self):
         os.mkdir('name with space')