Rev 6610: Fix pep8 in netrc_credential_store plugin. in file:///home/vila/src/bzr/experimental/py3/
Vincent Ladeuil
v.ladeuil+lp at free.fr
Wed Sep 2 09:16:32 UTC 2015
At file:///home/vila/src/bzr/experimental/py3/
------------------------------------------------------------
revno: 6610
revision-id: v.ladeuil+lp at free.fr-20150902091632-td1jtbiad73895pp
parent: v.ladeuil+lp at free.fr-20150902091357-qfaf0o6z71vitqop
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: pep8
timestamp: Wed 2015-09-02 11:16:32 +0200
message:
Fix pep8 in netrc_credential_store plugin.
-------------- next part --------------
=== modified file 'bzrlib/plugins/netrc_credential_store/__init__.py'
--- a/bzrlib/plugins/netrc_credential_store/__init__.py 2011-12-18 12:46:49 +0000
+++ b/bzrlib/plugins/netrc_credential_store/__init__.py 2015-09-02 09:16:32 +0000
@@ -18,9 +18,7 @@
__doc__ = """Use ~/.netrc as a credential store for authentication.conf."""
-# Since we are a built-in plugin we share the bzrlib version
-from bzrlib import version_info
-
+import bzrlib
from bzrlib import (
config,
lazy_import,
@@ -34,6 +32,8 @@
errors,
)
""")
+# Since we are a built-in plugin we share the bzrlib version
+version_info = bzrlib.version_info
class NetrcCredentialStore(config.CredentialStore):
@@ -71,5 +71,5 @@
'tests',
]
basic_tests.addTest(loader.loadTestsFromModuleNames(
- ["%s.%s" % (__name__, tmn) for tmn in testmod_names]))
+ ["%s.%s" % (__name__, tmn) for tmn in testmod_names]))
return basic_tests
=== modified file 'bzrlib/plugins/netrc_credential_store/tests/__init__.py'
--- a/bzrlib/plugins/netrc_credential_store/tests/__init__.py 2009-03-23 14:59:43 +0000
+++ b/bzrlib/plugins/netrc_credential_store/tests/__init__.py 2015-09-02 09:16:32 +0000
@@ -14,10 +14,11 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+
def load_tests(basic_tests, module, loader):
testmod_names = [
'test_netrc',
]
basic_tests.addTest(loader.loadTestsFromModuleNames(
- ["%s.%s" % (__name__, tmn) for tmn in testmod_names]))
+ ["%s.%s" % (__name__, tmn) for tmn in testmod_names]))
return basic_tests
=== modified file 'bzrlib/plugins/netrc_credential_store/tests/test_netrc.py'
--- a/bzrlib/plugins/netrc_credential_store/tests/test_netrc.py 2013-10-01 16:36:20 +0000
+++ b/bzrlib/plugins/netrc_credential_store/tests/test_netrc.py 2015-09-02 09:16:32 +0000
@@ -23,15 +23,13 @@
tests,
)
-from bzrlib.plugins import netrc_credential_store
-
class TestNetrcCSNoNetrc(tests.TestCaseInTempDir):
def test_home_netrc_does_not_exist(self):
- self.assertRaises(errors.NoSuchFile,
- config.credential_store_registry.get_credential_store,
- 'netrc')
+ self.assertRaises(
+ errors.NoSuchFile,
+ config.credential_store_registry.get_credential_store, 'netrc')
class TestNetrcCS(tests.TestCaseInTempDir):
@@ -51,7 +49,7 @@
osutils.chmod_if_possible(netrc_path, 0600)
def _get_netrc_cs(self):
- return config.credential_store_registry.get_credential_store('netrc')
+ return config.credential_store_registry.get_credential_store('netrc')
def test_not_matching_user(self):
cs = self._get_netrc_cs()
More information about the bazaar-commits
mailing list