def use_binary_basename_when_invoked_absolutely(self): Program().run("/usr/local/bin/myapp --help", exit=False) stdout = sys.stdout.getvalue() assert_contains(stdout, "myapp [--core-opts]") assert_not_contains(stdout, "/usr/local/bin")
def overrides_echoing(self): self._runner().run('invisible', hide=True, echo=True) assert_not_contains(sys.stdout.getvalue(), 'invisible')
def per_task_flags_complete_with_double_dashes(self): output = _complete('print-name --', 'integration') assert_contains(output, '--name') assert_not_contains(output, '-n\n') # newline because -n is in --name
def bare_double_dash_shows_only_long_core_options(self): output = _complete('--') assert_contains(output, '--no-dependencies') assert_not_contains(output, '-V')
def per_task_flags_complete_with_double_dashes(self): output = _complete('print_name --', 'integration') assert_contains(output, '--name') assert_not_contains(output, '-n\n') # newline because -n is in --name
def bare_double_dash_shows_only_long_core_options(self): output = _complete('--') assert_contains(output, '--no-dedupe') assert_not_contains(output, '-V')