Rev 2348: (John Whitley) Print out the location of ~/.bazaar as part of 'bzr --version' in http://bzr.arbash-meinel.com/branches/bzr/jam-integration
John Arbash Meinel
john at arbash-meinel.com
Mon Mar 12 21:57:59 GMT 2007
At http://bzr.arbash-meinel.com/branches/bzr/jam-integration
------------------------------------------------------------
revno: 2348
revision-id: john at arbash-meinel.com-20070312215713-sg04g24khpu222l8
parent: pqm at pqm.ubuntu.com-20070312212825-f3cc39efba5d38f8
parent: whitley at bangpath.org-20070312060419-e5dsbp3093f3razu
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: jam-integration
timestamp: Mon 2007-03-12 16:57:13 -0500
message:
(John Whitley) Print out the location of ~/.bazaar as part of 'bzr --version'
added:
bzrlib/tests/blackbox/test_version.py test_version.py-20070312060045-ol7th9z035r3im3d-1
modified:
bzrlib/tests/blackbox/__init__.py __init__.py-20051128053524-eba30d8255e08dc3
bzrlib/version.py version.py-20060816024207-ves6ult9a11taj9t-1
------------------------------------------------------------
revno: 2324.3.3
merged: whitley at bangpath.org-20070312060419-e5dsbp3093f3razu
parent: whitley at bangpath.org-20070312060237-sdfcipif2mxckp2j
parent: pqm at pqm.ubuntu.com-20070311211206-0fd0176ac1e77ef7
committer: John Whitley <whitley at bangpath.org>
branch nick: bug-90467
timestamp: Sun 2007-03-11 23:04:19 -0700
message:
Merged bzr.dev
------------------------------------------------------------
revno: 2324.3.2
merged: whitley at bangpath.org-20070312060237-sdfcipif2mxckp2j
parent: whitley at bangpath.org-20070308011749-jn2gand2rpkwqjhn
committer: John Whitley <whitley at bangpath.org>
branch nick: bug-90467
timestamp: Sun 2007-03-11 23:02:37 -0700
message:
Added blackbox test for bzr version.
------------------------------------------------------------
revno: 2324.3.1
merged: whitley at bangpath.org-20070308011749-jn2gand2rpkwqjhn
parent: pqm at pqm.ubuntu.com-20070307121852-b60a661123a5063d
committer: John Whitley <whitley at bangpath.org>
branch nick: bug-90467
timestamp: Wed 2007-03-07 17:17:49 -0800
message:
Reveal location of .bazaar directory in 'bzr version'
-------------- next part --------------
=== added file 'bzrlib/tests/blackbox/test_version.py'
--- a/bzrlib/tests/blackbox/test_version.py 1970-01-01 00:00:00 +0000
+++ b/bzrlib/tests/blackbox/test_version.py 2007-03-12 21:57:13 +0000
@@ -0,0 +1,32 @@
+# Copyright (C) 2007 Canonical Ltd
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+"""Black-box tests for bzr version."""
+
+import bzrlib
+from bzrlib.tests.blackbox import ExternalBase
+
+
+class TestVersion(ExternalBase):
+
+ def test_version(self):
+ out = self.run_bzr("version")[0]
+ self.assertTrue(len(out) > 0)
+ self.assertEquals(1, out.count(bzrlib.__version__))
+ self.assertEquals(1, out.count("Using python interpreter:"))
+ self.assertEquals(1, out.count("Using python standard library:"))
+ self.assertEquals(1, out.count("Using bzrlib:"))
+ self.assertEquals(1, out.count("Using bazaar configuration:"))
=== modified file 'bzrlib/tests/blackbox/__init__.py'
--- a/bzrlib/tests/blackbox/__init__.py 2007-03-09 04:02:35 +0000
+++ b/bzrlib/tests/blackbox/__init__.py 2007-03-12 06:04:19 +0000
@@ -96,6 +96,7 @@
'bzrlib.tests.blackbox.test_uncommit',
'bzrlib.tests.blackbox.test_update',
'bzrlib.tests.blackbox.test_upgrade',
+ 'bzrlib.tests.blackbox.test_version',
'bzrlib.tests.blackbox.test_version_info',
'bzrlib.tests.blackbox.test_versioning',
'bzrlib.tests.blackbox.test_whoami',
=== modified file 'bzrlib/version.py'
--- a/bzrlib/version.py 2007-01-18 23:20:16 +0000
+++ b/bzrlib/version.py 2007-03-12 06:02:37 +0000
@@ -20,7 +20,7 @@
import sys
import bzrlib
-from bzrlib import errors, osutils
+from bzrlib import config, errors, osutils
from bzrlib.branch import Branch
@@ -45,7 +45,7 @@
print repr(bzrlib.__path__)
else:
print bzrlib.__path__[0]
-
+ print "Using bazaar configuration:", config.config_dir()
print
print bzrlib.__copyright__
print "http://bazaar-vcs.org/"
More information about the bazaar-commits
mailing list