That's why they're called unit tests. They are supposed to test precisely one unit of functionality, while assuming everything else works as specified (using mocks if necessary).
Taking into account the effects of microcode execution on the test result is in fact a kind of integration testing.