Nepal has long been a buffer state between India and China, but with a new communist government at the helm, the Himalayan nation may now lean more toward Beijing.

Earlier this month, a coalition of two communist parties led by former prime ministers Pushpa Kamal Dahal and K.P. Sharma Oli emerged victorious in Nepal's general election — a vote seen as a milestone in the country's transition from monarchy to federal democracy.

The election will reveal "to what extent China will emerge as a viable alternative to India in Nepal's foreign policy," analysts at research firm Stratfor said in a recent note. "One thing, however, is for certain: the rivalry between India and China for influence in Nepal will only ramp up."

Landlocked Nepal is one of the world's most remote countries, and it has traditionally remained neutral in India and China's rivalry over economic and political clout in South Asia. New Delhi, Kathmandu's biggest trading partner, has been the dominant player, particularly under the pro-India government of Nepali Prime Minister Sher Bahadur Deuba.

That could change. Oli, who is expected to succeed Deuba, has promised to boost foreign investment and is seen cozying up to Beijing in the process.

Nepal is a part of China's Belt and Road network, a grand infrastructure scheme that China is using to expand trade — and influence. Chinese President Xi Jinping's administration has pledged billions to build sorely-needed infrastructure in Nepal.