private boolean makeSatisfied ( TestCaseDef testCase , VarTupleSet tuples ) { // Test case still missing a required property? boolean satisfied = testCase . isSatisfied ( ) ; if ( ! satisfied ) { // Yes, find tuples that contain satisfying bindings. int prevBindings = testCase . getBindingCount ( ) ; for ( Iterator < Tuple > satisfyingTuples = getSatisfyingTuples ( testCase , tuples ) ; // Does this tuple lead to satisfaction of all current test case conditions? satisfyingTuples . hasNext ( ) && ! ( satisfied = makeSatisfied ( testCase , tuples , satisfyingTuples . next ( ) ) ) ; // No, try next tuple testCase . revertBindings ( prevBindings ) ) ; } return satisfied ; }
Using selections from the given set of tuples completes bindings to satisfy all current test case conditions . Returns true if and only if all conditions satisfied .