A Whirlpool microwave is often treated as a replaceable kitchen workhorse, which makes a strict repair threshold especially useful. Using ~10 years as an average expected life, it can be reasonable to repair a younger unit for simple mechanical or switch failures if the estimate is safely under the threshold and the cabinet/interior are in good condition.
However, if heating performance is gone or intermittent, the likely culprits are high-voltage parts where repair costs and safety concerns rise quickly, making replacement the more conservative choice. Over-the-range installations add labor and may change the economics, but the same principle applies: avoid sinking large money into late-life units.
The replacement price here reflects a mainstream countertop microwave listing at a major home-improvement retailer; built-in and over-the-range models typically cost more.