def step_command_output_should_not_contain_exactly_text(context, text): expected_text = text if "{__WORKDIR__}" in text or "{__CWD__}" in text: expected_text = textutil.template_substitute(text, __WORKDIR__ = posixpath_normpath(context.workdir), __CWD__ = posixpath_normpath(os.getcwd()) ) actual_output = context.command_result.output textutil.assert_text_should_not_contain_exactly(actual_output, expected_text)
def step_command_output_should_not_contain_exactly_text(context, text): expected_text = text if "{__WORKDIR__}" in text or "{__CWD__}" in text: expected_text = textutil.template_substitute(text, __WORKDIR__ = posixpath_normpath(context.workdir), __CWD__ = posixpath_normpath(os.getcwd()) ) actual_output = context.command_result.output textutil.assert_text_should_not_contain_exactly(actual_output, expected_text)