| 
														
															@@ -5,6 +5,7 @@ import inspect 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 from io import StringIO 
														 | 
														
														 | 
														
															 from io import StringIO 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import logging 
														 | 
														
														 | 
														
															 import logging 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import random 
														 | 
														
														 | 
														
															 import random 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+import socket 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import stat 
														 | 
														
														 | 
														
															 import stat 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import subprocess 
														 | 
														
														 | 
														
															 import subprocess 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 import sys 
														 | 
														
														 | 
														
															 import sys 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -357,6 +358,16 @@ class ArchiverTestCase(ArchiverTestCaseBase): 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         # the interesting parts of info_output2 and info_output should be same 
														 | 
														
														 | 
														
															         # the interesting parts of info_output2 and info_output should be same 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         self.assert_equal(filter(info_output), filter(info_output2)) 
														 | 
														
														 | 
														
															         self.assert_equal(filter(info_output), filter(info_output2)) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+    def test_unix_socket(self): 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        self.cmd('init', self.repository_location) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        sock.bind(os.path.join(self.input_path, 'unix-socket')) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        self.cmd('create', self.repository_location + '::test', 'input') 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        sock.close() 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        with changedir('output'): 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            self.cmd('extract', self.repository_location + '::test') 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            assert not os.path.exists('input/unix-socket') 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+ 
														 | 
													
												
											
												
													
														| 
														 | 
														
															     def test_symlink_extract(self): 
														 | 
														
														 | 
														
															     def test_symlink_extract(self): 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         self.create_test_files() 
														 | 
														
														 | 
														
															         self.create_test_files() 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         self.cmd('init', self.repository_location) 
														 | 
														
														 | 
														
															         self.cmd('init', self.repository_location) 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -1244,6 +1255,9 @@ class ArchiverTestCase(ArchiverTestCaseBase): 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         try: 
														 | 
														
														 | 
														
															         try: 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             self.cmd('mount', self.repository_location, mountpoint, fork=True) 
														 | 
														
														 | 
														
															             self.cmd('mount', self.repository_location, mountpoint, fork=True) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             self.wait_for_mount(mountpoint) 
														 | 
														
														 | 
														
															             self.wait_for_mount(mountpoint) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            if has_lchflags: 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                # remove the file we did not backup, so input and output become equal 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                os.remove(os.path.join('input', 'flagfile')) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             self.assert_dirs_equal(self.input_path, os.path.join(mountpoint, 'archive', 'input')) 
														 | 
														
														 | 
														
															             self.assert_dirs_equal(self.input_path, os.path.join(mountpoint, 'archive', 'input')) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             self.assert_dirs_equal(self.input_path, os.path.join(mountpoint, 'archive2', 'input')) 
														 | 
														
														 | 
														
															             self.assert_dirs_equal(self.input_path, os.path.join(mountpoint, 'archive2', 'input')) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         finally: 
														 | 
														
														 | 
														
															         finally: 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -1265,6 +1279,9 @@ class ArchiverTestCase(ArchiverTestCaseBase): 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         try: 
														 | 
														
														 | 
														
															         try: 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             self.cmd('mount', self.repository_location + '::archive', mountpoint, fork=True) 
														 | 
														
														 | 
														
															             self.cmd('mount', self.repository_location + '::archive', mountpoint, fork=True) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             self.wait_for_mount(mountpoint) 
														 | 
														
														 | 
														
															             self.wait_for_mount(mountpoint) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            if has_lchflags: 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                # remove the file we did not backup, so input and output become equal 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                os.remove(os.path.join('input', 'flagfile')) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             self.assert_dirs_equal(self.input_path, os.path.join(mountpoint, 'input')) 
														 | 
														
														 | 
														
															             self.assert_dirs_equal(self.input_path, os.path.join(mountpoint, 'input')) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         finally: 
														 | 
														
														 | 
														
															         finally: 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             if sys.platform.startswith('linux'): 
														 | 
														
														 | 
														
															             if sys.platform.startswith('linux'): 
														 |