after that you go to hearthome city and fantina (the next gym leader) will be there.
P.S. i found this info on serebii.net. you should check it out.
Beat the Gym Leader
The fourth gym.
Go to the forth gym!
by beating the fourth gym leader
Flannery's gym in Lavaridge Town.
the fourth gym is in celadon city at the bottom left of the city. the gym leader is erika. the badge is called the rainbow badge
Beat the Gym Leader
The fourth gym.
Go to the forth gym!
Lavaridge town is where you get the fourth badge in ruby.Hint:the gym leader uses fire types so use a water type.
Defeat Flannery the lavaridge town gym leader.
by beating the fourth gym leader
misty
Flannery's gym in Lavaridge Town.
The 4th pokemon badge is given by Erika the Celadon City Gym Leader.
Directly to the right of the city with the fourth badge.
Flannery, a fire type gym leader.