The `setup_config_file` was modified to have a `write_config` method
that abstracts the file writing so that we can modify multiple types of
config settings.
Also, the empty IP Queue test is mostly self-contained, but it does
clean up a global variable that's modified, just in case.
Because of the size of the test code change itself, this patch doesn't
include any changes to the dynamic inventory script itself.
Change-Id: If6adb9c55fd03f2e5b7b21469667971767663075