It's trickier with such deep manipulations actually, and it always depends on the specific case.
Your idea of changing everything to private could break in various places when internal declaration is actually accessible in some way. E.g. it's allowed to call internals of the main module in the test module. Or you could have public open class with an internal member and inheritor of it in the other module, and compiler could try to generate a bridge method to this internal from the base class (can't provide the exact example though).