Invalid mount mode for volumes in

Add test for invalid mount mode for volumes in.
Closes #8389.
Can we check that the error we are getting back is because `bar` is an invalid mode and it's not because the container `foo` does not exist?