From 41652a49cbd99ea129b36834faf5ba7508f3f617 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Mon, 5 Sep 2011 15:35:02 -0700 Subject: tests/emerge: test egencache This tests --update in any case, and --update-use-local-desc only if python xml support is detected. --- bin/egencache | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'bin') diff --git a/bin/egencache b/bin/egencache index 53ae56582..bf29474ef 100755 --- a/bin/egencache +++ b/bin/egencache @@ -772,8 +772,6 @@ def egencache_main(args): parser, options, atoms = parse_args(args) config_root = options.config_root - if config_root is None: - config_root = '/' # The calling environment is ignored, so the program is # completely controlled by commandline arguments. @@ -790,8 +788,10 @@ def egencache_main(args): if options.portdir is not None: env['PORTDIR'] = options.portdir + eprefix = os.environ.get("__PORTAGE_TEST_EPREFIX") + settings = portage.config(config_root=config_root, - target_root='/', local_config=False, env=env) + local_config=False, env=env, _eprefix=eprefix) default_opts = None if not options.ignore_default_opts: @@ -800,14 +800,11 @@ def egencache_main(args): if default_opts: parser, options, args = parse_args(default_opts + args) - if options.config_root is not None: - config_root = options.config_root - if options.cache_dir is not None: env['PORTAGE_DEPCACHEDIR'] = options.cache_dir settings = portage.config(config_root=config_root, - target_root='/', local_config=False, env=env) + local_config=False, env=env, _eprefix=eprefix) if not options.update and not options.update_use_local_desc \ and not options.update_changelogs: -- cgit v1.2.3-1-g7c22