summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2009-03-03 03:39:57 +0000
committerZac Medico <zmedico@gentoo.org>2009-03-03 03:39:57 +0000
commita517752edabe43a429ea4687d0fbb7516645ac1d (patch)
tree4374a505022b595f856982f29abebcc03e9e2fbd
parentde02b26b05da45db8ab2449959b0699eb1f3bd59 (diff)
downloadportage-a517752edabe43a429ea4687d0fbb7516645ac1d.tar.gz
portage-a517752edabe43a429ea4687d0fbb7516645ac1d.tar.bz2
portage-a517752edabe43a429ea4687d0fbb7516645ac1d.zip
Make KeyValuePairFileLoader store the values as a strings instead of a lists.
svn path=/main/trunk/; revision=12744
-rw-r--r--pym/portage/env/loaders.py2
-rw-r--r--pym/portage/tests/env/config/test_PortageModulesFile.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/pym/portage/env/loaders.py b/pym/portage/env/loaders.py
index 53566625c..e031ed60f 100644
--- a/pym/portage/env/loaders.py
+++ b/pym/portage/env/loaders.py
@@ -275,7 +275,7 @@ class KeyValuePairFileLoader(FileLoader):
% (line_num + 1, line))
return
key = split[0].strip()
- value = split[1].split()
+ value = split[1].strip()
if not key:
errors.setdefault(self.fname, []).append(
"Malformed key at line: %s, key %s"
diff --git a/pym/portage/tests/env/config/test_PortageModulesFile.py b/pym/portage/tests/env/config/test_PortageModulesFile.py
index d8938d8c5..fb164b4a7 100644
--- a/pym/portage/tests/env/config/test_PortageModulesFile.py
+++ b/pym/portage/tests/env/config/test_PortageModulesFile.py
@@ -22,7 +22,7 @@ class PortageModulesFileTestCase(TestCase):
f = PortageModulesFile(self.fname)
f.load()
for k in self.keys:
- self.assertEqual(f[k], [self.items[k]])
+ self.assertEqual(f[k], self.items[k])
for ik in self.invalid_keys:
self.assertEqual(False, ik in f)
self.NukeFile()