MDL-48356 moodle_formatter: don't use any core stuff on dry runs

Because of a big number of dependencies, it's not possible
to run core stuff with --dry-run, mainly because CFG and
other setup stuff is not called in those runs.

So, keeping it simple, the beforeSuite() hook will simply do
nothing (printing the headers) when CFG is not defined.