Framework for Optimized Regression Testing