[test] functional: set cwd of nodes to tmpdir (Sjors Provoost)
Pull request description:
Any process launched by bitcoind will have `self.datadir` as its `cwd`.
https://github.com/bitcoin/bitcoin/pull/15415/commits/e3e1a5631e2456bb40844862ef35c07c1d1c47b0
Depends on D7080
Backport of Core PR15415