"In a unit test, mock objects can simulate the behavior of complex, real (non-mock) objects and are therefore useful when a real object is impractical or impossible to incorporate into a unit test."
Why would you want to simulate the graphics subsystem (and therefore the video card)?
The goal here isn't performance testing. It's to check whether the engine works.
You aren't testing the engine. You are testing that the unit, in your example the class Foo, responds correctly to the state and inputs you provide it. Decoupling those responses from other units such as the graphics subsystem gives you the assurance that under the tested conditions the unit works as intended.
What you are talking about is a regression or functional test. Same genus different species, still very useful but not the same tool.
Edit: Going to bed, if someone would like to explain by morning why this needed to be down voted so brutally I would be much obliged!
It's impossible to unit test a component whose criteria for 'working' is tightly coupled to dependencies out of your control (video hardware & drivers).
Thus you'll never be able to unit-test a video game completely. Or even fulfill other forms of testing with the same breadth as is possible in other software, unless you have every possible configuration to test on, or stick with consoles. Games are among the buggiest of all software, but it's not for want of trying!
Yes, it's true that unit testing those components of a video game that abstract away the hardware underneath is hard or even practically impossible. But Foo here is not talking to hardware. It uses a model given by GrSubsys and that model can be mocked.
Why would you want to simulate the graphics subsystem (and therefore the video card)?
The goal here isn't performance testing. It's to check whether the engine works.