@tdb3 I’ve pushed an update. Adding the users to the existing list is a better approach. However, some tests are now failing because users are whitelisted in the run_test function, while the new tests are designed to test instances when a user is not whitelisted.
I thought clearing the bitcoin.conf file before writing the new test would solve this issue, but it doesn’t. Below is a sample output for the bitcoin.conf
file in the test_rpcwhitelist_default_0_without_whitelist
function:
0rpcwhitelistdefault=0
1rpcauth=user1:50358aa884c841............................................................
2rpcauth=user2:8650ba41296f6..........................................
3rpcauth=user3:50358aa8..................................................
Despite having new permissions, users are still whitelisted, and thus this assertion would fail:
assert_equal(200, rpccall(self.nodes[0], user[0], "getbestblockhash", user[3]).status)
Why would this happen? The new tests are still reading permissions from therun_test
function and not the new bitcoin.conf