With the Wildcats trailing by two points, Lyons drove to the basket and was fouled by Skylar Spencer. His two foul shots gave Arizona (12-0) the lead for good.
The Aztecs (11-2) got the ball back and Chase Tapley had a chance for the win, but Nick Johnson blocked his shot off the glass at the buzzer, handing the Wildcats the win in the championship game of the Diamond Head Classic in Hawaii.
Solomon Hill scored 21 points with six rebounds and Kevin Parrom added 17 points off the bench for the Wildcats.
Tapley finished with 19 points for San Diego State, which saw its 11-game winning streak snapped.
Exploding whale video goes viral on Internet
Gal Gadot cast as Wonder Woman for 'Batman vs. Superman'