Messed up bash variable string interpolation in test scripts