[PATCH 2/5] tests: cleanup whitespace in simpleconfig_test.py

Vratislav Podzimek vpodzime at redhat.com
Thu Aug 9 07:42:42 UTC 2012


On Wed, 2012-08-08 at 14:49 -0700, Brian C. Lane wrote:
> From: "Brian C. Lane" <bcl at redhat.com>
> 
> ---
>  tests/pyanaconda_test/simpleconfig_test.py |   42 ++++++++++++++--------------
>  1 files changed, 21 insertions(+), 21 deletions(-)
> 
> diff --git a/tests/pyanaconda_test/simpleconfig_test.py b/tests/pyanaconda_test/simpleconfig_test.py
> index 467e993..ab59f5d 100644
> --- a/tests/pyanaconda_test/simpleconfig_test.py
> +++ b/tests/pyanaconda_test/simpleconfig_test.py
> @@ -6,13 +6,13 @@ import sys
>  
>  class SimpleconfigTest(mock.TestCase):
>      def setUp(self):
> -        self.setupModules(["_isys", "block", "ConfigParser"])        
> +        self.setupModules(["_isys", "block", "ConfigParser"])
>          self.fs = mock.DiskIO()
>          import pyanaconda.simpleconfig
>          pyanaconda.simpleconfig.open = self.fs.open
>          pyanaconda.simpleconfig.os = mock.Mock()    # Mock os module
>          pyanaconda.simpleconfig.os.path = os.path   # except os.path part
> -        
> +
>          # Stuff for IfcfgFile class tests
>          self.DIR = '/etc/sysconfig/network-scripts/'
>          self.IFACE = 'eth0'
> @@ -20,12 +20,12 @@ class SimpleconfigTest(mock.TestCase):
>          self.CONTENT = '# Broadcom Corporation NetXtreme BCM5761 Gigabit Ethernet\n'
>          self.CONTENT += 'DEVICE=eth0\n'
>          self.CONTENT += 'HWADDR=00:10:18:61:35:98\n'
> -        self.CONTENT += 'ONBOOT=no\n'      
> -        self.fs.open(self.PATH, 'w').write(self.CONTENT)
> -    
> +        self.CONTENT += 'ONBOOT=no\n'
> +        open(self.PATH, 'w').write(self.CONTENT)
Shouldn't self.fs.open be here?

-- 
Vratislav Podzimek

Anaconda Rider | Red Hat, Inc. | Brno - Czech Republic



More information about the anaconda-patches mailing list