You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ansible/test/integration/targets/lineinfile/tasks
Sam Doran 4b5b4a760c
Account for empty string regexp in lineinfile (#41451)
* Use context managers for interacting with files

* Account for empty string as regexp

Rather than explicitly testing for None, also test for an empty string which will evaluate to False. An empty string regexp matches every line, which ends up replacing the incorrect line.

* Store line parameter in a variable

* Add tests
6 years ago
..
main.yml Account for empty string regexp in lineinfile (#41451) 6 years ago