Kernel.exec ~ expansion bug

When setting an SSH key in .kitchen.yml with a path starting with a ~, Kernel.exec will not expand ~ to $HOME when passed as an element in an Array.