Testing check-ins before building can be achieved through
Incremental Check-ins
Test driven development
Gated Check-ins
Continuous integration