Combine olive oil, garlic, salt, and pepper flakes in a medium saucepan. Add tomatoes and green beans. Place over medium-low heat, and cook, covered, stirring occasionally, for 15 minutes. Add basil, and cook, covered, for 5 minutes more. Serve hot or at room temperature.