test tcp_keepidle only if it's available on the current platform

keystone.common.environment conditionally sets TCP_KEEPIDLE only if it's
available (as it's not expected to be available in the OS X version of
eventlet). However, this test always fails on OS X because it's assuming
that both socket options are always set.

Change-Id: I368e5414d37ad265d12b9bf6f19d40e0c1f653a9
Closes-Bug: 1296768
Create TMPDIR for tests recursively

keystone/tests/tmp is missing in the sdist tarballs, so
we need to not only create keystone/tests/tmp/<pid> but also the
parent directory. Use os.makedirs for that.

Change-Id: I2f97bee517297b9fa239183c23ad1dfa52505bc9
Closes-Bug: #1296862
Merge "Create TMPDIR for tests recursively"