Is this a tub/shower? Not sure what you mean by faucet here, do you want to turn that off independent of the mixing valve (most have on/off flow built-in). If it's a tub spout, the easiest way is to use a tub spout with a built-in diverter.
That rough-in valve has male threads on it (I think). On the one I last installed, the inside of that hole was designed to accept a pipe OR to use a threaded female adapter, so you can just solder the pipe into that opening. A soldered connection is more rugged than a threaded one, and then you don't have to worry about a lousy, made in China female threaded adapter with torn or improperly cut threads. Just leave the cartridge out while doing the soldering.
If you use a tub spout with a diverter, you don't need anything to keep the water from going out the showerhead while using the spout...IF you follow the instructions - you cannot use pex to the spout, or you will have problems. Because there's less restriction for it to go out the spout, it doesn't back up and go out the showerhead until you block that outlet.