That is correct.
There is a diagnostic charge initially and it is the same as most manufacturers under the approved used scheme or extended warranty. If the fault is found and covered by the warranty then it'll be waived and everything fixed under the warranty.
If not, you usually pay the diagnostic charge and then the dealer will give you a quote which you can choose to accept or not.
More than likely the sunroof drains are blocked, more so if the car has spent time under trees