I suspect they wouldn't know about universal gravitation, without astromonical observations to suggest it. The prevalent theory would be that entire universe is made of rock; borings into their surroundings would support this (unless they reached the surface, which our scenario here excludes.) Objects at lower levels, closer to the COM, would weigh less (linearly in r); they would have a phenomenological explanation for this ("mass ~ distance from point X"). This would be a huge mystery; why is this point X they extrapolate, so special? Why is mass disappearing as you approach X? Then someone might notice, inertial mass is conserved! But weight is not! Their primitive concept of "gravity" would be this mysterious ratio of weight/intertial mass. Extrapolating out linearly, there would be places where (gravity) is arbitrarily strong - this would also be pathological. Their cosmology would be a severe mystery to them, just like our own accelerating universe mystifies us. The most obvious solution for them, would be to compactify their universe; there would be no reason for them to think of an infinite universe, with gravitational acceleration being linear in r out to infinity (!). Thus I believe their mainstream model of a universe, for most of their history, would be compact.
What would suggest an extraplanetary world to them? Tidal forces in gravity, would find an alternative explanation easily enough, in their compact-universe model. The problem with living deep underground, is that there's really no EM radiation reaching you at all! Particle physics would have to be the answer. They look at radioactive materials, and conclude something big happened billions of years ago. Harnessing nuclear fusion, someone might point out that, certain features of their terrestial distribution of elements are suprisingly consistent with a radical new idea - that at one point, everything came from a giant nuclear reactor operating at 3x10^7 Kelvin. Was this the early universe? Impossible; it couldn't have cooled down in a compact universe. Nucleosynthesis would be the key to their discovering the outside world, I predict.
Particle physics comes along by itself pretty well. They'd discover natural magnets, and static electricity, and a few years later they have cyclotrons and LINACs. Their first neutrino would be a single, unrepeatble event (like that monopole someone thought they saw...). Some brave soul, with too much funding, builds a super-huge target (like our Super-K) and confirms that neutrinos are real, though very rare! Over time, mysterious bursts of neutrino activity would find no convenient explanation. Another mystery, to them as profound as, say, dark matter.
Of course how could they possibly extrapolate the real nature of the universe, from these strange phenomena?