added tests for set_condition