Fix an issue with resource policy test