Best definition
when the going gets good
a phrase used to indicate that something with happen when <insert positive thing(s) here> begin to happen. The phrase says

1) that things are going to get better and 2) that is when the mentioned event or state of being will commence.
see also: the going is good good going and how’s it going

example 1:

guy: “do you think 3 people will be enough to run an entire company?”

boss: “it’s enough to start with, we’ll hire more when the going gets good”

example 2:

dude: “yo man, I heard you started dealin’ again… you buy yerself a new TV set yet”

other dude: “nah man, I aint ballin yet, but you know i’ll hook myself up when the going gets good, dig?”

dude: “werd”