Allow testing in production mode

I found tests sometimes fail in production mode because code is minimized. This allows testing in production mode if wanted.