Related question I had for a looong time: how do submarine cable layer ships test the cable when they attach a new section? Like, these cables need many kilovolts of voltage to supply the inline repeaters so you can only power them when the cable is fully laid, but how do they verify if the fibers aren't broken somewhere along the path?
But after a repair they are probably tested on deck by re-energizing the cable from the landing stations. Although, they might behave differently when on deck than on the bottom due to the different dielectric constant of water and air.