If a traffic light has been green for a long time:

If you are approaching a traffic light that has been green for a long time, there is a good chance that it will turn yellow before you reach it. Start slowing down and be ready to stop.
DMV Writen Test