Fix potential fd leak

Always close the test socket.

Change-Id: Ic87b713a7791cf39ed5146754e1345fc662c894e
Make floating_ip_bulk_destroy deallocate quota if not auto_assigned

The expected use case for floating_ip_bulk_destroy is to destroy
auto_assigned floating IPs, for which no quota is used so no quota
needs to be recovered.  But it can also be used to destroy other
(not auto_assigned) floating IPs, in which case the previously used
quota was not recovered.  This fixes the quota leak in that unusual
case.

Closes-Bug: #1254174

Change-Id: Ibff80d9ebac8d4422e401909033da12d9ec0b593
Do not set root device for libvirt+Xen

Currently we are setting the root device for Xen when using libvirt.
When a user is booting an image that contains a full partitioned disk it
fails, since the root device will be passed as "root=/dev/whatever" as
the cmdline to the booting kernel.

Closes-Bug: 1253626
Change-Id: Ia5e3ee8891759c68ee51b219d1a7f80d0afbeffc
Test guestfs without support for close_on_exit

A previous commit, fd621ef05a024b8319f2c67f7e5c084b9ab77755, fixed support for
versions of libguestfs that did not support the close_on_exit parameter.  This
patch adds unit test coverage for that code path.

Change-Id: Ic3cc0057e24ac00e6435a9555a19c076ddc9b02e
Related-Bug: #1271562
Related-Bug: #1261475
Sync latest gettextutils from oslo-incubator

The translation message improvements are the main addition of
interested because they are required to support lazy message
evaluation.

Commits included:

  afdbc0ac5 Fix E501 in individual openstack projects
  6b2d15fe6 Merge "Add support for locales missing from babel"
  9d529dd32 Make Message keep string interpolation args
  ec6d90019 Add support for locales missing from babel
  221c37d44 Allow the Message class to have non-English default locales
  0e1af5bed Implementation of translation log handler
  f5686b19d Merge "Translation Message improvements"
  8b2b0b743 Use hacking import_exceptions for gettextutils._
  2cfc1a78d Translation Message improvements
  45658e2f3 Fix violations of H302:import only modules

Note that the following touched other files, but the changes were
independent and did not require inclusion of additional files:

  8b2b0b743 Use hacking import_exceptions for gettextutils._
  45658e2f3 Fix violations of H302:import only modules

Partially implements blueprint i18n-messages

Change-Id: I3ac748d0cf73d841330675e8eb02a5bb1bbc9f1e
Disable file injection in baremetal by default

DocImpact: This disables file injection by default for baremetal. File
injection has never been very useful for baremetal given the much
wider set of device configurations vs virtual, so it's unlikely anyone
was using this (it cannot be used in a heterogeneous OS image
environment, for instance). We should still document the change
though.

UpgradeImpact

blueprint disable-file-injection-by-default

Change-Id: I60a108ef1f0e46ad4da94d2a730426e255011476
Co-Authored-By: Steve Kowalik <steven@wedontsleep.org>
Merge "Disable file injection in baremetal by default"
Merge "Fix potential fd leak"
Merge "Sync latest gettextutils from oslo-incubator"
Merge "Do not set root device for libvirt+Xen"
Merge "Make floating_ip_bulk_destroy deallocate quota if not auto_assigned"
Merge "Test guestfs without support for close_on_exit"