Trim ends off green beans.
Blanch green beans in a pot of boiling water then strain.
In a separate pan warm olive oil over medium heat. Saute onions until golden, about 7 minutes.
Add crushed garlic and diced tomatoes and stir frequently for about 2 minutes, then toss green beans and cook to your desired finish.