Optimized guard

Only build what is necessary to run tests after a file change