Bug 1282256 - Remove MozbuildObject._config_guess. r=gps

Back when it was added, it was used, but it is not anymore, outside
test_base.py.

--HG--
extra : rebase_source : f0b9a4dab2985e89e9950eda774ae853c7de764c
This commit is contained in:
Mike Hommey 2016-08-04 10:07:56 +09:00
Родитель 6168f0df5b
Коммит ad5e3fa4c4
2 изменённых файлов: 3 добавлений и 19 удалений

Просмотреть файл

@ -90,7 +90,6 @@ class MozbuildObject(ProcessExecutionMixin):
self._make = None
self._topobjdir = mozpath.normsep(topobjdir) if topobjdir else topobjdir
self._mozconfig = mozconfig
self._config_guess_output = None
self._config_environment = None
self._virtualenv_manager = None
@ -443,14 +442,6 @@ class MozbuildObject(ProcessExecutionMixin):
self.log(logging.WARNING, 'notifier-failed', {'error':
e.message}, 'Notification center failed: {error}')
@property
def _config_guess(self):
if self._config_guess_output is None:
self._config_guess_output = MozbuildObject.resolve_config_guess(
self.mozconfig, self.topsrcdir)
return self._config_guess_output
def _ensure_objdir_exists(self):
if os.path.isdir(self.statedir):
return

Просмотреть файл

@ -60,7 +60,9 @@ class TestMozbuildObject(unittest.TestCase):
self.assertIsNotNone(base.topobjdir)
self.assertEqual(len(base.topobjdir.split()), 1)
self.assertTrue(base.topobjdir.endswith(base._config_guess))
config_guess = MozbuildObject.resolve_config_guess(base.mozconfig,
base.topsrcdir)
self.assertTrue(base.topobjdir.endswith(config_guess))
self.assertTrue(os.path.isabs(base.topobjdir))
self.assertTrue(base.topobjdir.startswith(base.topsrcdir))
@ -298,15 +300,6 @@ class TestMozbuildObject(unittest.TestCase):
os.chdir(self._old_cwd)
shutil.rmtree(d)
def test_config_guess(self):
# It's difficult to test for exact values from the output of
# config.guess because they vary depending on platform.
base = self.get_base()
result = base._config_guess
self.assertIsNotNone(result)
self.assertGreater(len(result), 0)
def test_config_environment(self):
base = self.get_base(topobjdir=topobjdir)