2017 update: this answer is accurate, Gengar gets Cursed Body when trasferred. Levitate is gone for good.
I find it highly probable that the answer will be no, Gengar will not retain Levitate upon transfer to Sun or Moon. Gen 7 is not the first time Pokemon have had changes in their abilities; with the release of X and Y, Chandelure and Scolipede had their Hidden Abilities changed to Infiltrator and Speed Boost respectively. Whilst Chandelure was never released with its Hidden Ability for Gen 5's duration, Scolipede was. It is seen that upon transferring a Quick Feet Scolipede to Gen 6, its ability is indeed changed to Speed Boost. (Bulbapedia supports this; hover the asterisk on the "Abilities" section of this page.)
It would be against the past treatment of these changes if Gengar were to retain Levitate when transferred to Gen 7, so I think it's likely that Gengar's ability will be changed to Cursed Body. In addition, if Gengar were to keep Levitate, it would make the change in ability pointless from a practical perspective; Gengar would still have access to and use the ability. Obviously we won't know an answer for sure until the PokeBank update rolls out, but I don't think Gengar will be switching into any more Earthquakes this generation, unfortunately.
(Note, I don't think the existing answer is wrong per se, I just thought this perspective should be given mention.)