SEOUL—North Korea slammed China’s “insincerity and betrayal” in a commentary published late Wednesday, calling statements in the official Chinese media “an undisguised threat” to Pyongyang, as it sought to stave off pressure from Beijing on its nuclear and missile programs.

“China should no longer try to test the limits of the DPRK’s patience,” North Korea said in the commentary published by the official Korean Central News Agency, using the acronym for its formal name, the Democratic People’s Republic of Korea. “China had...