Ganache and Infura are two very different things.
Ganache is a tool for quickly creating a local network that can be used for development. It can be used to automatically run tests, etc. completely locally, without relying on one of the public testnets (Goerli, Ropsten, etc.).
Infura is a infrastructure provider, primarily for Ethereum. It provides access to the Ethereum mainnet and the different public testnets. While you could use one of the testnets for running tests, Ganache is much easier to quickly set up for testing. If you want to test a more real world scenario, you can use Infura for deploying your smart contracts to the mainnet or one of the testnets.