Merge lp:~nskaggs/ubuntu-filemanager-app/fix-xauthority into lp:ubuntu-filemanager-app

Proposed by Nicholas Skaggs
Status: Merged
Approved by: Arto Jalkanen
Approved revision: 535
Merged at revision: 532
Proposed branch: lp:~nskaggs/ubuntu-filemanager-app/fix-xauthority
Merge into: lp:ubuntu-filemanager-app
Prerequisite: lp:~nskaggs/ubuntu-filemanager-app/add-dep-cache
Diff against target: 34 lines (+0/-18)
1 file modified
tests/autopilot/filemanager/tests/__init__.py (+0/-18)
To merge this branch: bzr merge lp:~nskaggs/ubuntu-filemanager-app/fix-xauthority
Reviewer Review Type Date Requested Status
Jenkins Bot continuous-integration Approve
Ubuntu File Manager Developers Pending
Review via email: mp+288838@code.launchpad.net

Commit message

Remove unneeded _copy_xauthority_file

Description of the change

Remove unneeded _copy_xauthority_file

To post a comment you must log in.
Revision history for this message
Jenkins Bot (ubuntu-core-apps-jenkins-bot) :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'tests/autopilot/filemanager/tests/__init__.py'
2--- tests/autopilot/filemanager/tests/__init__.py 2016-03-07 15:15:45 +0000
3+++ tests/autopilot/filemanager/tests/__init__.py 2016-03-11 21:17:45 +0000
4@@ -157,23 +157,6 @@
5 directory = registry.get_path(package_name)
6 return version, directory
7
8- def _copy_xauthority_file(self, directory):
9- """ Copy .Xauthority file to directory, if it exists in /home
10- """
11- # If running under xvfb, as jenkins does,
12- # xsession will fail to start without xauthority file
13- # Thus if the Xauthority file is in the home directory
14- # make sure we copy it to our temp home directory
15-
16- xauth = os.path.expanduser(os.path.join(os.environ.get('HOME'),
17- '.Xauthority'))
18- if os.path.isfile(xauth):
19- logger.debug("Copying .Xauthority to %s" % directory)
20- shutil.copyfile(
21- os.path.expanduser(os.path.join(os.environ.get('HOME'),
22- '.Xauthority')),
23- os.path.join(directory, '.Xauthority'))
24-
25 def patch_home(self):
26 """ mock /home for testing purposes to preserve user data
27 """
28@@ -188,7 +171,6 @@
29 temp_dir = temp_dir_fixture.path
30
31 # before we set fixture, copy xauthority if needed
32- self._copy_xauthority_file(temp_dir)
33 self.useFixture(fixtures.EnvironmentVariable('HOME',
34 newvalue=temp_dir))
35

Subscribers

People subscribed via source and target branches