The government has historically tried to avoid doing so, but had to dip into the funds in 2016–2018. The rules around spending was formalized in 2001 [2], but the extent to which Norway was dipping into the funds has been controversial the last few years, with economists warning that it puts the country at risk in a future economic downturn.
Norway's wealth fund is actually codified as law, which makes it difficult for a future government to "steal" it.
[1] https://www.bloomberg.com/news/articles/2018-05-02/norway-st...
[2] https://www.regjeringen.no/no/tema/okonomi-og-budsjett/norsk...
We simply don't do corrupt to any significant degree. Probably the niftiest social trick the Scandinavian societies ever evolved.
Come to think of it, I was offered a bribe today, just a few hours ago. Turned it down without even thinking.